Command line path completion is a feature that seems to be randomly enabled or disabled depending on which version of Windows XP or 2000 you are using. When you are typing the path to a file in the command prompt window, command line path completion allows you to press the Tab key to have Windows fill in the names of matching files and folders.

For this post, we are going to enable command line path completion in Windows XP. The procedure is the same for Windows 2000. To begin, select Run from the Start menu.

Selecting Run from the Start menu

On the Run dialog box, enter ‘”regedit” (without the quotes) in the Open edit box and click OK.

Entering regedit on the Run dialog box

On the Registry Editor dialog box, browse to the following section:

HKEY_LOCAL_MACHINE | SOFTWARE | Microsoft | Command Processor

Right-click on the CompletionChar key in the right pane and select Modify from the popup menu.

03_modifying_completionchar

On the Edit DWORD Value dialog box for the CompletionChar key, change the value in the Value data edit box to 9, which is the ASCII value for the Tab key. Click OK.

Changing the CompletionChar value to 9

Access the Edit DWORD Value dialog box for the PathCompletionChar key the same way you did for the CompletionChar key. Change the value in the Value data edit box to 9. Click OK.

Changing the PathCompletionChar value to 9

To close the Registry Editor, select Exit from the File menu. Your changes are automatically saved.

Closing the Registry Editor

To see how the command line path completion feature works, we will open a command prompt window. Select Run from the Start menu again, as mentioned earlier in this post. Enter “cmd” (without the quotes) in the Open edit box. Click OK.

Opening a command window

Enter “cd ..” (again, without the quotes) at the command prompt enough times to get back to the root directory of C:. Type the following and press Tab:

cd c:\do

Start typing a directory name

The system finds the first folder that matches. Keep hitting the Tab key and the system cycles through all of the matches. If you hold down the Shift key while pressing the Tab key and the system cycles through the matches in reverse. Press Enter to go to the directory.

Directory name completed

If you would rather use a key a Ctrl key combination, see the ASCII Character Set for a chart of ASCII Control Characters and their corresponding Ctrl key combinations (in the Control-Key column).

Command line path completion can save you a lot of time if you who frequently use the command prompt.

by Lori Kaufman