Has anyone come across a "good" method for bypassing the UAC prompt (in Windows 7 Pro) when calling applications from scripts?
So far, none of the methods I've found are appealing:
1. Disable UAC entirely - Obviously not a good idea.
2. Include "RunAs" in the command line - Can't hide the password and don't want the user to be prompted for anything. Also, I doubt that this would work because I still get the prompt if I right-click the executable and select "Run as administrator".
3. Run the application via Task Scheduler - Not desirable because I don't want to set up a task on every machine just for this script. Might consider this if I can figure out how to automate the process of creating the task, and then remove the task after the application has started.
4. Use a third party app to elevate the privileges of the application. - Don't want to use 3rd party apps unless necessary.
Are there any other methods I might have missed? What's everyone else using to get around this annoyance?
So far, none of the methods I've found are appealing:
1. Disable UAC entirely - Obviously not a good idea.
2. Include "RunAs" in the command line - Can't hide the password and don't want the user to be prompted for anything. Also, I doubt that this would work because I still get the prompt if I right-click the executable and select "Run as administrator".
3. Run the application via Task Scheduler - Not desirable because I don't want to set up a task on every machine just for this script. Might consider this if I can figure out how to automate the process of creating the task, and then remove the task after the application has started.
4. Use a third party app to elevate the privileges of the application. - Don't want to use 3rd party apps unless necessary.
Are there any other methods I might have missed? What's everyone else using to get around this annoyance?