Created
November 6, 2014 12:23
-
-
Save JohnLBevan/909358b8f403c64dc267 to your computer and use it in GitHub Desktop.
Run powershell as different user as admin. From http://blogs.technet.com/b/benshy/archive/2012/06/04/using-a-powershell-script-to-run-as-a-different-user-amp-elevate-the-process.aspx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Start-Process powershell.exe -Credential "TestDomain\Me" -NoNewWindow -ArgumentList "Start-Process powershell.exe -Verb runAs" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment