Sets an EXE to run as Administrator. Usage: SetExeToRunAsAdmin -Path <exe path> (-CurrentUser | -AllUsers)

Alternatively you can use the -UnsetInstead parameter to unset the exe to run as administrator.

Installation Options

Copy and Paste the following command to install this package using PowerShellGet More Info

Install-Script -Name SetExeToRunAsAdmin

You can deploy this package directly to Azure Automation. Note that deploying packages with dependencies will deploy all the dependencies to Azure Automation. Learn More

Manually download the .nupkg file to your system's default download location. Note that the file won't be unpacked, and won't include any dependencies. Learn More





PowerShell Windows exe set run remove unset administrator add compatibility admin




This script has no dependencies.

Release Notes

[Version 0.0.1] - Initial Release.
[Version 0.0.2] - Fixed example.
[Version 0.0.3] - Added option to unset the exe to run as administrator and refactored function code.
[Version 0.0.4] - Fixed bug in version specification and improved examples.
[Version 0.0.5] - Added project link and improved tags.
[Version 0.0.6] - Fixed version specification.
[Version 0.0.7] - Final version specification fix.
[Version 0.0.8] - Improved description.

Version History

Version Downloads Last updated
0.0.8 (current version) 23 9/3/2022
0.0.7 5 9/3/2022
0.0.6 5 9/3/2022
0.0.4 5 9/3/2022
0.0.3 6 9/3/2022
0.0.2 33 7/6/2022
0.0.1 7 7/6/2022