No REG Command in "Open elevated command window here" DOS Box

Page 1 of 4 123 ... LastLast

  1. Posts : 24
    Windows 7 Professional x64 SP1
       #1

    No REG Command in "Open elevated command window here" DOS Box


    I have used the @="cmd.exe /s /k pushd \"%V\"" type of Registry mod to obtain a context menu "Open elevated command window here" menu item, such as in the "Open elevated command window here" thread ( Open elevated command window here ).

    However, the admin cmd window, even though it says "Administrator:" in the title bar, will not seem to work with the REG command (e.g., "REG SAVE [...]", etc.). If I even just type "reg /?" on the cmd line, it just jumps to the next (new) cmd line prompt, without any apparent action. (And, DISKPART will work here, even though REG doesn't.)

    [The REG command works fine when I open a pinned cmd.exe link with Admin privileges.]

    So,

    1. Has anyone else noticed this?

    2. And, if I'm not the only user in the universe to have this "feature", does anyone know of a workaround?

    Thanks.
    Last edited by Brink; 15 May 2012 at 11:40. Reason: fixed link
      My Computer


  2. Posts : 72,043
    64-bit Windows 11 Pro for Workstations
       #2

    Hello Fred, and welcome to Seven Forums.

    Is this the tutorial you used below to add "Open elevated command window here"?
    The REG /? command works for me using this when I right clicked on C:\Users and Open elevated command window here.
    No REG Command in "Open elevated command window here" DOS Box-cmd.jpg
    Do you have your UAC notification settings set to at least the default or top level? Normally when you use "Open elevated command window here", you will get a UAC prompt to approve before the elevated CMD window opens. If you do not get a UAC prompt, then this may be why you are having this issue.

    Hope this helps for now,
    Shawn
    Last edited by Brink; 15 May 2012 at 16:21. Reason: correction
      My Computer


  3. Posts : 24
    Windows 7 Professional x64 SP1
    Thread Starter
       #3

    Brink said:
    Hello fwcetus, and welcome to Seven Forums.

    Is this the tutorial you used below to add "Open elevated command window here"? Open Command Window Here as Administrator
    Yes. (And thanks for the welcome.)

    Brink said:
    The REG /? command works for me using this when I right clicked on C:\Users and Open elevated command window here.
    Still not for me, though.

    Brink said:
    Do you have your UAC notification settings set to at least the default or top level? Normally when you use "Open elevated command window here", you will get a UAC prompt to approve before the elevated CMD window opens. If you do not get a UAC prompt, then this may be why you are having this issue.
    I do have UAC set at "Default" (the second one down).

    I do get a UAC msgbox when invoking the context menu admin CMD box.

    I noticed that your CMD box shows "C:\Windows\System32\cmd.exe" in the title bar, while mine shows "C:\Windows\SysWOW64\cmd.exe", yet we are both using x64 Windows 7.

    So, I put the path "C:\Windows\System32\cmd.exe" into the reg file and merged it, but (even though the Registry does show my ""C:\Windows\System32\cmd.exe" change in Regedit) my CMD box still comes up with the "C:\Windows\SysWOW64\" CMD box anyway. ("Windows Knows Best.")

    So, I then tried copying "C:\Windows\System32\cmd.exe" into "C:\Windows\" and merged ""C:\Windows\cmd.exe" into the Registry, and I did finally get a "C:\Windows\System32\" copy of CMD to run (from "C:\Windows\") from the context menu, but it still won't process the REG command.

    It seems as if I can run at least some other elevated commands (I didn't try them all - <g> ), but not REG.

    I noticed that "REG" is not listed in a typical list of CMD commands for some reason, even though it functions as one (well, usually).

    I guess, this is not really a huge problem - I can still get REG to work from my pinned (Start Menu) admin CMD box, and in batch files, too. However, I'm just trying to figure out Windows' irregularities... (As a retired software engineer, I know that, when it comes to Windows, "it's not all ones and zeroes" - <g> .)
    Last edited by fwcetus; 15 May 2012 at 14:22. Reason: Added a clarification
      My Computer


  4. Posts : 72,043
    64-bit Windows 11 Pro for Workstations
       #4

    Hmm, that is odd.

    As a test, use the same tutorial above to remove the context menu item, then add it back. Next, download and merge the listed CMD option in the tutorial below to see if that may help.

    Default File Type Associations - Restore
      My Computer


  5. Posts : 24
    Windows 7 Professional x64 SP1
    Thread Starter
       #5

    Brink said:
    Hmm, that is odd.

    As a test, use the same tutorial above to remove the context menu item, then add it back. Next, download and merge the listed CMD option in the tutorial below to see if that may help.

    Default File Type Associations - Restore
    No changes, Brink, either in which CMD box runs (still SysWOW64) or in how REG works (still doesn't). Thanks for trying...
      My Computer


  6. Posts : 5,092
    Windows 7 32 bit
       #6

    It seems like you are getting Registry and Folder redirection to the 32 bit emulation( the SysWow64 )

    On some versions of Windows 7 and Vista if you open Explorer from a 32 bit program, you will actually get the 32 bit explorer from the SysWow64 folder. In fact I was using that with a utility to get 32 bit shell extensions to work on 64 bit Windows. But there seems to be no way to tell if the Explorer in SysWow64(which is a link) points to 32 bit or 64 bit Explorer.

    Anyway, the short version is, it sounds to me like you are running the .reg file in a 32 bit Explorer window, which would trigger registry and folder redirection. Try opening an Explorer window using the taskbar button. Then look in TaskManager to make sure it's 64 bit. If it is, then run the .reg download. See what happens.

    Please make a restore point first so I don't get blamed if what happens, happens to be something weird. :)
      My Computer


  7. Posts : 24
    Windows 7 Professional x64 SP1
    Thread Starter
       #7

    Update: (and, before having a chance to mull over MilesAhead's post)

    I happened to try "Open[ing] Command Window Here as Administrator", with "C:\Windows\System32\" as the directory, and then with "C:\Windows\SysWOW64\" as the directory, and, in both cases, REG works as it should.

    However, selecting any other directory (including other ""C:\Windows\" subdirectories) and "Open[ing] Command Window Here as Administrator" results in a CMD box where REG does not work.

    Reg.exe is, of course, located in both "C:\Windows\System32\" and "C:\Windows\SysWOW64\", not surprisingly.

    Strange...
      My Computer


  8. Posts : 24
    Windows 7 Professional x64 SP1
    Thread Starter
       #8

    MilesAhead said:
    It seems like you are getting Registry and Folder redirection to the 32 bit emulation( the SysWow64 )
    [...]
    Anyway, the short version is, it sounds to me like you are running the .reg file in a 32 bit Explorer window, which would trigger registry and folder redirection. Try opening an Explorer window using the taskbar button. Then look in TaskManager to make sure it's 64 bit. If it is, then run the .reg download. See what happens
    Thanks, MilesAhead, for your thoughts.

    Well, every instance of Explorer (explorer.exe) I can invoke (in a variety of ways) seems to be a 64-bit version - that is to say that I never see any "explorer.exe *32" processes, but only "explorer.exe" processes (from "C:Windows"), in TaskMan.

    However, I did merge the "Default_REG.reg" settings, and I rebooted (just for the heck of it), but my "Open Command Window Here as Administrator" menu item still pops up a "C:\Windows\SysWOW64\" copy of cmd.exe, that will not run the REG command (except in "C:\Windows\System32\" or in "C:\Windows\SysWOW64\". (?)
    Last edited by fwcetus; 15 May 2012 at 16:25. Reason: Correction
      My Computer


  9. Posts : 72,043
    64-bit Windows 11 Pro for Workstations
       #9

    It wouldn't be the "explorer.exe" process. It should be a "cmd.exe" process instead of a "cmd.exe *32" one.

    Did you merge the Default_CMD.reg instead earlier?

    If you like as a test, create a new administrator account to see how it works while logged on to the new account.
      My Computer


  10. Posts : 5,092
    Windows 7 32 bit
       #10

    Brink said:
    It wouldn't be the "explorer.exe" process. It should be a "cmd.exe" process instead of a "cmd.exe *32" one.

    Did you merge the Default_CMD.reg instead earlier?

    If you like as a test, create a new administrator account to see how it works while logged on to the new account.
    It would be Explorer.exe if he ran it by double clicking the .reg file in a 32 bit instance of explorer. Whichever it is, it still sounds like he's getting the 32 bit emulation redirection.

    I have my own PromptHere you can download here:
    http://www.favessoft.com/hotkeys.html

    It has the ahk source code. You can download AHK_L and compile in 64 bit if you want. Anyway, it doesn't rely on the registry since it doesn't do context menu. It uses a hotkey. Select a folder and hit the hotkey.

    Uses optional blur window on W7.
      My Computer


 
Page 1 of 4 123 ... LastLast

  Related Discussions
Our Sites
Site Links
About Us
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
All times are GMT -5. The time now is 04:06.
Find Us