Windows 10 Tweak: Change Command Prompt to PowerShell as Default in WinX Menu Action

Update: 10/17/2016 – Confirmed works on 1607 & Server 2016
For in place upgrades, recommend using Group Policy to add registry Keys
image

 image

image

 

Or simply run this to add it to your own profile… (requires log off & log on)
REG ADD "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /V DontUsePowerShellOnWinX /T REG_DWORD /D 00000000 /F

________________________
Original Post:
So you love to Right-Click on the Start Button and have access to all those Great Tools, but why did Microsoft default the Option to Command Prompt instead of PowerShell?  Don’t they know PowerShell is king?  So I decided to make it default during OSD via a registry setting.

The Registry Key is for HKCU, so we’ll apply it to the default profile, so anyone who logs on for the first time will get that key added to their HKCU.

 

WinXMenu-CMD2PS.reg
--------------------------
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\defuser\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced]
"DontUsePowerShellOnWinX"=dword:00000000
----------------------------

WinXMenu-CMD2PS.CMD

----------------------------

reg.exe load HKEY_LOCAL_MACHINE\defuser c:\users\default\ntuser.dat
reg.exe import "WindowsXMenu\WinXMenu-CMD2PS.reg"
reg.exe unload HKEY_LOCAL_MACHINE\defuser
--------------------------------

Add those two files into your Windows10OSD Scripts Package,

image

You can find the files available here: OSDWindows10Scripts.zip

Then you can add a step to your TS to call the batch file
image

Now, after you image Windows 10, instead of the Command Prompt, you’ll get PowerShell for all users:
image

 

Other handy Info:
Manually change this by going to TaskBar & Start Menu Properties (right click on TaskBar and click Properties) then check the box under Navigation:
image

You can add other items to this menu for your profile by adding times here:
C:\Users\[USERNAME]\AppData\Local\Microsoft\Windows\WinX directory

 

More great info:
http://pcsupport.about.com/od/termsp/g/power-user-menu-win-x.htm

2 thoughts on “Windows 10 Tweak: Change Command Prompt to PowerShell as Default in WinX Menu Action

  • August 8, 2018 at 7:57 pm
    Permalink

    it is very informative. But, when I run .cmd I get the following messages:

    C:\WINDOWS\system32>reg.exe load HKEY_LOCAL_MACHINE\defuser c:\users\default\ntuser.dat
    The operation completed successfully.

    C:\WINDOWS\system32>reg.exe import D:\OSDWindows10Scripts\OSDWindows10Scripts\WindowsXMenu\"WinXMenu-CMD2PS.reg"
    ERROR: Error opening the file. There may be a disk or file system error.

    C:\WINDOWS\system32>reg.exe unload HKEY_LOCAL_MACHINE\defuser
    The operation completed successfully.

    Can you please help.

    Thanks
    Tariq

    Reply
    • August 13, 2018 at 11:15 am
      Permalink

      the step you're running, it is looking to D:\OSDWindows10Scripts\OSDWindows10Scripts\WindowsXMenu\"WinXMenu-CMD2PS.reg" for the registry file, are you coping the file to that location before running the step? Also, in 1709 and above, you don't need that step, PowerShell is the default in the WinX menu now.

      Reply

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.