PRB: Can't Open or Save a File Named CON or LPT1

Last reviewed: August 1, 1995
Article ID: Q133456
The information in this article applies to:
  • Microsoft Visual FoxPro for Windows, version 3.0

SYMPTOMS

Typing in a file name of CON in an open or save dialog box in Visual FoxPro running on Windows 3.1 or Windows for Workgroups 3.11 causes the computer to hang (stop responding). If you are running on Windows NT or Windows 95 you will receive this error:

   The filename is a reserved device name. Use a different filename.

CAUSE

The filename CON is a valid pre-existing Device in MS-DOS. It is the same as trying to use LPT1 as a file name.

RESOLUTION

Do not use reserved words or device names as a name for a file.

STATUS

This behavior is by design.

MORE INFORMATION

Steps to Reproduce Problem

  1. Type MODIFY CLASS in the Command window.

  2. Type CON in the class library name box of the Open dialog box.

  3. Press ENTER or click Open.


Additional reference words: 3.00 VFoxWin
KBCategory: kbenv kbprb
KBSubcategory: FxenvOs


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: August 1, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.