Disclaimer: As with any registry action, please make sure you perform a full registry backup first! You are entirely responsible for modifying your registry and by using this registry mod, you agree to hold me, WordPress, affiliates and everyone else completely harmless of anything and everything that happens! In general, you should not download .reg files. If you do, thoroughly review every line (notepad) before running it! As with any site, I encourage you to read each line of this registry mod before running it!
I often find myself browsing some file or folder location in Windows Explorer and find that I need to run something from the command-line (e.g. batch file, command-line utility, etc.). However, the command prompt opens to the current user’s profile folder (e.g. C:\Users\%userprofile%) by default. This is generally far from where I need to be. So I end up having to change directories all the way to the path I was browsing, hoping I remember the entire path.
To make things easier I made a little registry mod that adds an “Open Folder in CMD” option to the right-click menu for folders, files and the desktop. After running the mod, all you have to do is right-click any folder, file or the desktop and select “Open Folder in CMD”. It will then open the command prompt directly to the folder you just right-clicked on! It saves a ton of time and hassle trying to get back into the same folder. Here is what it looks like from the Desktop (at left).
You can use this mod anywhere Windows Explorer exists. Some examples are inside of a File Open or Close Dialog, from auto-search results in the Run box, etc. Below is an example of running it from within Windows Explorer itself. If you click a file, it opens the folder containing that file.
To install this registry modification, simply do the following.
- Download the file from here.
- Open Notepad.
- Click File -> Open.
- Browse to where you stored the file and click Open.
- Review the contents to be sure you’re comfortable with it.
- Close Notepad.
- Rename the end of the file from .xlsx (Excel) to .reg (Registry Import/Export).
- This is required because most modern browsers, antivirus, etc. will not allow download of registry files. So, we had to trick it. If it still won’t download, please leave a comment and I might just have to post the text in this post so you can copy & paste it into your own .reg file.
- Double-click the .reg file.
That’s it! You’re all done. It takes effect immediately, without you having to restart Windows. I’ve tried this on Windows 7 and it works great. It should work on others as well, but not sure how far back it’ll work (2000, XP, etc.). If you find out, please let me know in the comments section!
I hope this helps save you time, as it does for me!