Sometimes I want to open a command prompt to a certain folder. In my example, I want to open a CMD prompt to the folder Downloads on my drive E:. I could just open up CMD prompt that defaults to C:\Users\Terry and then navigate to E:\Downloads. I could download a registry tweak to have it as a right-click context menu option.
If you don't want to chance with the reg file, there is still another way to do it. Just open up File Explorer to the folder of your choice. In the explorer bar across the top where the path is displayed. In my case it's listed as This PC > back1 (E:) > Downloads.
If I click in that bar it changes the display slightly, as in my case E:\Downloads. You can also see it's highlighted.
Now I just type cmd. Then I just hit enter and the cmd prompt opens at the folder I specified.
If you want the registry tweak, just copy and paste the following into a text (notepad) file and change the extension to .reg file. Depending on your editor, change the file type from txt to all files types.
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Directory\shell\cmd2]
@="@shell32.dll,-8506"
"Extended"=-
"Icon"="imageres.dll,-5323"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOT\Directory\shell\cmd2\command]
@="cmd.exe /s /k pushd \"%V\""
[HKEY_CLASSES_ROOT\Directory\Background\shell\cmd2]
@="@shell32.dll,-8506"
"Extended"=-
"Icon"="imageres.dll,-5323"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOT\Directory\Background\shell\cmd2\command]
@="cmd.exe /s /k pushd \"%V\""
[HKEY_CLASSES_ROOT\Drive\shell\cmd2]
@="@shell32.dll,-8506"
"Extended"=-
"Icon"="imageres.dll,-5323"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOT\Drive\shell\cmd2\command]
@="cmd.exe /s /k pushd \"%V\""
[HKEY_CLASSES_ROOT\LibraryFolder\Background\shell\cmd2]
@="@shell32.dll,-8506"
"Extended"=-
"Icon"="imageres.dll,-5323"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOT\LibraryFolder\Background\shell\cmd2\command]
@="cmd.exe /s /k pushd \"%V\""
Once your reg file is created, doubleclick on it and accept all prompts.
If it doesn't show up right away, restart your system. In my case I didn't need a restart.