Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am making the menu items called Lock for Microsoft's BitLocker. I've got it all right up to one point: locking HDD partitions requires administrator privileges.
How do I use process paths or CMD or something similar to start an application elevated, with arguments?

share|improve this question
up vote 0 down vote accepted

You need the Elevation Powertoy for Vista. It also works on Windows 7.

share|improve this answer

Use the RUNAS command and put your application name and its arguments within double quotes.

RUNAS /user:machinename\administrator "app arg1 arg2 \"filename with spaces\""
share|improve this answer
The RUNAS command will execute C:\Windows\system32\runas.exe with the given arguments. That application does not require administrator rights and it doesn't work, because I have tried. Anyway, I will try again, but do I need to specify the user? I mean... Can you show me a working example of executing notepad with administrator rights? – Vercas Dec 9 '10 at 17:56
@Vercas: runas /user:administrator notepad works for me. I can type some text and save the file in a protected directory. – Dennis Williamson Dec 9 '10 at 18:51
It asks me for my password and it does nothing after I type it. – Vercas Dec 9 '10 at 19:43

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.