PowerShell: Elevated Command

With User Account Control (UAC) dialog:

Start-Process wt.exe -verb runas
Start-Process -file powershell.exe -verb runas
powershell.exe -Command Start-Process -file "cmd.exe" -verb runas

Without User Account Control (UAC) dialog, but you need to enter administrator’s password.

runas /user:administrator "cmd.exe"

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *