locked
Startup Script: Access Denied RRS feed

  • Question

  • I am trying to set up a Windows 10 image to be deployed throughout a school district and we have a script that runs on start up to make setting it up easier that connects it to the network, renames computer, adds it to the domain, and then deletes itself.  The script works fine if ran as Administrator but I do not know how to make it automatically run as Administrator.  Any help would be greatly appreciated.
    • Moved by Bill_Stewart Monday, March 7, 2016 9:47 PM Off-topic
    Wednesday, January 27, 2016 1:39 PM

Answers

  • It sounds like you have a Windows deployment question rather than a scripting question.

    I would suggest researching Windows deployment tools (such as Microsoft Deployment Toolkit, etc.) and find out a better way to accomplish what you need.


    -- Bill Stewart [Bill_Stewart]

    • Proposed as answer by jrv Wednesday, January 27, 2016 3:37 PM
    • Marked as answer by Bill_Stewart Monday, March 7, 2016 9:47 PM
    Wednesday, January 27, 2016 3:08 PM

All replies

  • See the post right at the top of this forum:

    You cannot bypass the UAC prompt


    -- Bill Stewart [Bill_Stewart]

    Wednesday, January 27, 2016 1:55 PM
  • if the startup script is configured through taskscheduler try this;

    powershell.exe -File .\startupscript.ps1 -verb Runas

    HTH


    Cheers, Matthew Kerfoot

    Wednesday, January 27, 2016 2:00 PM
  • Which is why I am posting in a scripting forum to find a way to do what this script did, which ran in Windows Vista and 7 perfectly fine, so I do not have to manually change name, add to domain, etc of over 700 computers.  I figured someone has more experience with scripting then I do and could help me either make a new one or find a different way to accomplish this.
    • Edited by augerot25 Wednesday, January 27, 2016 2:52 PM
    Wednesday, January 27, 2016 2:51 PM
  • It sounds like you have a Windows deployment question rather than a scripting question.

    I would suggest researching Windows deployment tools (such as Microsoft Deployment Toolkit, etc.) and find out a better way to accomplish what you need.


    -- Bill Stewart [Bill_Stewart]

    • Proposed as answer by jrv Wednesday, January 27, 2016 3:37 PM
    • Marked as answer by Bill_Stewart Monday, March 7, 2016 9:47 PM
    Wednesday, January 27, 2016 3:08 PM