Saturday, December 15, 2007

DOS prompt in any folder

Ever need to quickly get a DOS prompt in a certain folder? It is not easy to do in a standard windows configuration. I often need to get a DOS prompt to run various tools (e.g. Perl tools), and it frustrated me that I have to open a command prompt (i.e. cmd) and then navigate to the folder.

So here is the solution. It is a small registry tweak that allows you to right-click on any folder and get a prompt. Simply paste the following into a file with extension .reg and execute it. In an Explorer window you can also right-click on the folder icon in the very top left corner to get a DOS prompt.

Nifty.

REGEDIT4
[HKEY_CLASSES_ROOT\Folder\shell\Prompt\command]
""="cmd.exe /n \"%1\""

1 comment:

Michael erwin said...

This function is also provided in the "Powertoys for Windows XP" package.