Errors Changing Directory at Command Prompt

ID: Q155262


The information in this article applies to:
  • Microsoft Windows NT Server version 4.0
  • Microsoft Windows NT Workstation version 4.0


SYMPTOMS

When you try to change to a directory with a long file name at a command prompt, you may receive one of the following error messages:

Too many parameters
Parameter format not correct
Invalid directory


CAUSE

These error messages are caused by the use of Command.com instead of Cmd.exe in the console.

Command.com is included in Windows NT 4.0 for backward compatibility, and contains very little support for long file names.


RESOLUTION

To work around this behavior, use either of the following methods:

  • Use Cmd.exe instead of Command.com. To do so, follow these steps:


    1. Click the Start button, point to Settings, click Taskbar, and then click the Start Menu Programs tab.


    2. Click Add.


    3. Type "cmd.exe" (without quotation marks), and then click Next.


    4. Type a descriptive name such as "Shortcut to Cmd.exe" and then click Finish.


  • Use the short name for the directory you want to change to. To see the directory's short name, type "dir /x" (without quotation marks).



MORE INFORMATION

The error message "Too many parameters" occurs when there is a space in the long directory name and the name is enclosed in quotation marks. "Parameter format not correct" occurs when there are no spaces but the name is enclosed in quotation marks. "Invalid directory" occurs when there are no quotation marks.

Command.com can be used accidentally if the computer is upgraded from Windows or Windows for Workgroups version 3.x. The Command Prompt icon remains in the Programs group, and the group is converted to shortcuts by Windows NT 4.0 Setup.

Additional query words:


Keywords          : kbenv ntdosap NTSrvWkst prodnt 
Version           : winnt:4.0
Platform          : winnt 
Issue type        : kbprb 


Last Reviewed: February 28, 1999
© 1999 Microsoft Corporation. All rights reserved. Terms of Use.