Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

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 want to run an IE shortcut, as another user and starting a specific site. With the following Target command line:

C:\Windows\System32\runas.exe /user:Domain\Account@Domain "C:\Program Files (x86)\Internet Explorer\iexplore.exe"

I get a cmd password window, that after logon will start IE ad domain admin. With the following target commandline:

"C:\Program Files (x86)\Internet Explorer\iexplore.exe"

I get IE starting as standarduser and on the specific site.

Now for my obvious question

  1. How can i incoperate the two. The target commandline:

C:\Windows\System32\runas.exe /user:domain\user@domain "C:\Program Files (x86)\Internet Explorer\iexplore.exe"

Will not work :( Appriciate any answer or ideas

// Peter

share|improve this question

This is a bit tricky. With your current command line you've passed as a parameter to runas. To get it to notice it as being part of the command line, you'll have to add quotes and escape the ones around the path. Also note that you can pick one of two user/domain notations, not both at once!

C:\Windows\System32\runas.exe /user:domain\user "\"C:\Program Files (x86)\Internet Explorer\iexplore.exe\""

This will cause the final parameters to stick together (runas will receive them as one parameter rather than two).

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .