Comment changer "Ouvrir avec Powershell" to "Ouvrir avec Commande Prompt" when shift-rightclicking in Explorer?

ForumBot
Messages : 26117
Inscription : mer. avr. 22, 2026 5:33 pm

Comment changer "Ouvrir avec Powershell" to "Ouvrir avec Commande Prompt" when shift-rightclicking in Explorer?

Message par ForumBot »

Shift-rightclicking an empty spot in Explorer displays *"Open with PowerShell"* instead of *"Open with Invite de commandes"* since the [Creators Update](https://en.wikipedia.org/wiki/Windows_10_version_history#Version_1703_(Creators_Update)) (2017-04). Comment puis-je get the old behaviour back where it shows *"Open with Invite de commandes"*?

J'ai essayé changing the setting *"Show PowerShell instead of Invite de commandes when rightclicking the menu Démarrer or pressing Windows + X"* to off, but that didn't change the shift+rightclick menu.
ForumBot
Messages : 26117
Inscription : mer. avr. 22, 2026 5:33 pm

Re: Comment changer "Ouvrir avec Powershell" to "Ouvrir avec Commande Prompt" when shift-rightclicking in Explorer?

Message par ForumBot »

Open regedit.exe, allez dans `HKEY_CLASSES_ROOT\Directory\shell\cmd`, [take ownership of the key](http://winaero.com/comment.php?comment.news.210), add your compte utilisateur full permissions and change the name of the DWORD from `HideBasedOnVelocityId` to `ShowBasedOnVelocityId` to [enable the invite de commandes entry again](https://www.deskmodder.de/blog/2016/12/10/eingabeaufforderung-wieder-im-kontextmenue-der-windows-10-creators-update-anzeigen).

Or apply [Andrew Richards tweak to have both shown](https://blogs.msdn.microsoft.com/andrew_richards/2017/03/01/enhancing-the-open-command-prompt-here-shift-right-click-context-menu-experience/) (cmd and PowerShell, also with entry to have elevate (running en tant qu'administrateur) version),

by importing his .reg file (create a new txt file, paste the content and rename the extension de fichier to reg):

```
Windows Registry Editor Version 5.00

; Command Prompt

[HKEY_CLASSES_ROOT\Directory\shell\01MenuCmd]
"MUIVerb"="Command Prompts"
"Icon"="cmd.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuCmd"

[HKEY_CLASSES_ROOT\Directory\background\shell\01MenuCmd]
"MUIVerb"="Command Prompts"
"Icon"="cmd.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuCmd"

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\open]
"MUIVerb"="Command Prompt"
"Icon"="cmd.exe"

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\open\command]
@="cmd.exe /s /k pushd \"%V\""

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\runas]
"MUIVerb"="Command Prompt Elevated"
"Icon"="cmd.exe"
"HasLUAShield"=""

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""

; PowerShell

[HKEY_CLASSES_ROOT\Directory\shell\02MenuPowerShell]
"MUIVerb"="PowerShell Prompts"
"Icon"="powershell.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuPowerShell"

[HKEY_CLASSES_ROOT\Directory\background\shell\02MenuPowerShell]
"MUIVerb"="PowerShell Prompts"
"Icon"="powershell.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuPowerShell"

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\open]
"MUIVerb"="PowerShell"
"Icon"="powershell.exe"

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\open\command]
@="powershell.exe -noexit -command Set-Location '%V'"

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\runas]
"MUIVerb"="PowerShell Elevated"
"Icon"="powershell.exe"
"HasLUAShield"=""

[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\runas\command]
@="powershell.exe -noexit -command Set-Location '%V'"

; Ensure OS Entries are on the Extended Menu (Shift-Right Click)

[HKEY_CLASSES_ROOT\Directory\shell\cmd]
"Extended"=""

[HKEY_CLASSES_ROOT\Directory\background\shell\cmd]
"Extended"=""

[HKEY_CLASSES_ROOT\Directory\shell\Powershell]
"Extended"=""

[HKEY_CLASSES_ROOT\Directory\background\shell\Powershell]
"Extended"=""

```
Répondre

Revenir à « Windows 10 »