Windows 7 Forums Search
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows 7. The Windows 7 forum also covers news and updates and has an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7 - Open Command Window Here as Administrator

 
12-16-2009   #9
Brink


Windows 7 Ultimate x64 SP1
 
 

Open Command Window Here as Administrator

Add or Remove "Open Command Window Here as Administrator" to the Context Menu

...


Last edited by Brink; 1 Week Ago at 11:43 AM..
My System SpecsSystem Spec
06-10-2010   #10
Brink


Windows 7 Ultimate x64 SP1
 
 


Hello Rover,

I'm not sure why you and SIW had a issue with this Open Command Window Here as Administrator and the Take Ownership context menu items working with both added to the context menu separately. I have not had any issues with them.


Last edited by Brink; 06-11-2010 at 02:55 PM.. Reason: updated
My System SpecsSystem Spec
06-11-2010   #11
rover3500


windows 7 Premium
 
 


Yeah,sorry I meant SIW2,got names mixed up.
Thanx for ur help Brink,they both work fine now thanx to u.
My System SpecsSystem Spec
06-12-2010   #12
Brink


Windows 7 Ultimate x64 SP1
 
 


Quote   Quote: Originally Posted by Brink View Post
Hello Rover,

I'm not sure why you and SIW had a issue with this Open Command Window Here as Administrator and the Take Ownership context menu items working with both added to the context menu separately. I have not had any issues with them.
Update.

I have updated the Open Command Window Here as Administrator and the Take Ownership downloads so that installing one will completely remove the other one so it will not cause issues. I have not found a way to have both in the context menu at the same time yet since they both use the runas key and cannot use it at the same time.
My System SpecsSystem Spec
06-13-2010   #13
rover3500


windows 7 Premium
 
 

To Brink

I just tried it to make sure,and since the change

ie:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\shell\Command as Admin]

[HKEY_CLASSES_ROOT\Directory\shell\Command as Admin\command]
@="cmd.exe /s /k pushd \"%V\""

Not inside run as,it works fine.
I just took over a folder and got up a command window as admin while it was doing it.
Definitely works for me now,thanx Brink.
My System SpecsSystem Spec
.


06-13-2010   #14
Brink


Windows 7 Ultimate x64 SP1
 
 


Hello Rover,

Sorry, but it's not a elevated command prompt.

If you type diskpart (requires elevated command prompt to use) and press enter in the command prompt that you open using the above, UAC will prompt you to then elevate the command prompt. The "C:\Windows\system32.cmd.exe" in the tiltle bar is misleading since a title bar does not indicate whether it's elevated or not.

Thank you though.
My System SpecsSystem Spec
11-23-2011   #15
DocMagoo


Windows 7 Ultimate x64
 
 


Hello All,

As a possible solution to having both an Elevated Prompt and the Take Ownership menu option in the context menu, what I have found that you can do is first install the Take Ownership registry file. For the Elevated Command Prompt, the process is a little bit more involved.

The first step is to copy the cmd.exe file from C:\Windows\System32 directory to C:\Windows. The next and key step is to change the properties of the cmd.exe file that you just copied in to the C:\Windows directory. What you want to do is to change the Compatibility settings for the cmd.exe file and check the box for "Run this program as an administrator". The next few steps are just to manually edit the registry settings to add the Elevated Command Prompt context menu choice.

In HKCR>Directory>shell, create the key ElevatedPrompt. For the Default REG_SZ setting, change the value to "Open Elevated Command Prompt Here". Next, create a new string value called Icon and assign is the value "C:\Windows\cmd.exe". Now, create a sub key from ElevatedPrompt called "command". Inside this sub key, assign the default value of cmd.exe /s /k pushd "%V".

Repeat the above steps in HKCR>Drive>shell.

Now, you should have both Take Ownership and Elevated Command Prompt active in the context menu.

I hope this helps.

Doc.
My System SpecsSystem Spec
Comment

 Open Command Window Here as Administrator problems?



Tutorial Tools



Similar Threads for: Open Command Window Here as Administrator
Windows 7 Tutorial Category
Open Command Window Here - Add or Remove Tutorials
Open Command Window Here Tutorials
Open Command Window Here General Discussion
Problem open command Window(administrator) Network & Sharing
Solved Open elevated command window here General Discussion


All times are GMT -5. The time now is 02:40 AM.



Windows 7 Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows 7" and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30