Errors Changing Directory at Command Prompt

Last reviewed: March 27, 1997
Article 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 : 4.0
Platform : WinNT
Issue type : kberrmsg


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: March 27, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.