vote up 3 vote down
star
1

Without having to navigate all the way to the directory I want.

flag
add comment

8 Answers:

vote up 6 vote down
check

You may want to look at this "PowerToy" from Microsoft:

Open Command Window Here

This PowerToy adds an "Open Command Window Here" context menu option on file system folders, giving you a quick way to open a command window (cmd.exe) pointing at the selected folder.

link|flag
I think this answer combined with Michael Ratanapintha's answer about using shift-right click in vista and 2008 answers this question fully. – Joshua Hudson Sep 14 at 2:51
add comment
vote up 3 vote down

This might be what you want:

cmd /K "cd C:\Windows\"
link|flag
add comment
vote up 3 vote down

If you have Vista or Server 2008, right-click on the directory icon in Explorer while holding the Shift key, and then click the "Open Command Window Here" context menu option. For XP, use the PowerToy mentioned by dF to get the same function.

link|flag
I'm running Server 2008 here and I don't get an "Open Command Window Here" context menu option when I Shift+right-click on a directory... ...doesn't work on Vista x64 either. – raven Oct 18 at 21:20
add comment
vote up 2 vote down

The XP powertoy is a good option, but I thought I'd post another, in case you'd like to "roll your own". Create a text file, name it anything.reg, paste in the code below, save it, then double-click on it to add it to the registry (or just add the info to the registry manually if you understand what's going on in this .reg file).

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Folder\shell\Command_Prompt_Here...]
@="Command Prompt Here..."

[HKEY_CLASSES_ROOT\Folder\shell\Command_Prompt_Here...\command]
@="cmd.exe \"%1\""
link|flag
add comment
vote up 1 vote down

Use the /K switch. For example

cmd /K "cd /d c:\WINDOWS\"

Will create a cmd window at the C:\Windows directory

link|flag
add comment
vote up 0 vote down

Create a shortcut and edit the "Start In" property of the shortcut to the directory you want the cmd.exe to start in.

link|flag
add comment
vote up 0 vote down

Right click the desktop and navigate to new and then from the sub-menu select "shortcut">>Browse to the windows directory (or folder) and then to the system32 directory and click ok. add a \ and "cmd.exe" (without the qoutes) to the command string. Should look like this...C:\WINDOWS\System32\cmd.exe. Click next and finish. Right click the new CMD icon on your desktop and select properties, and next to the Start In options delete the line and add the path to where ever the directory is that you want it to start in...I.E., c:\temp\mp3 and click ok.

link|flag
add comment
vote up -1 vote down

Already answered here

link|flag
add comment

Your Answer:

Get an OpenID
or

Not the answer you're looking for? Browse other questions tagged or ask your own question.