PRB: Splitting a Filename in a Command Line Causes Error

Last reviewed: June 27, 1995
Article ID: Q111318
The information in this article applies to:
  • Microsoft FoxPro for Windows, versions 2.5, 2.5a, and 2.5b
  • Microsoft FoxPro for MS-DOS, versions 2.0, 2.5, 2.5a, and 2.5b
  • Microsoft FoxPro for Macintosh, version 2.5b

SYMPTOMS

Using a semicolon (;) to split a filename over two or more lines in a command line generates the error message Unrecognized phrase/keyword in command."

RESOLUTION

To use a semicolon to break program lines containing filenames, use one of the following two methods:

  • Do not break the line in the middle of the filename. Use the following method for splitting the command line instead:

          USE;
          C:\FOXPROW\TUTORIAL\CUSTOMER
    

    -or-

  • Surround the file designation with quotation marks:

          USE "C:\FOXPROW\TUT;
          ORIAL\CUSTOMER"
    

MORE INFORMATION

Steps to Reproduce Behavior

  1. Assuming you do not already have a program called TEST.PRG, create a program called TEST.PRG that contains the following lines of code. You can substitute any directory path to a valid .DBF file.

          USE C:\FOXPROW\TUT;
          ORIAL\CUSTOMER
    

  2. Save the program, and type "DO test" (without the quotation marks) in the FoxPro Command window.

You should receive an "Unrecognized phrase/keyword in command" error.


Additional reference words: FoxMac FoxDos FoxWin 2.00 2.50 2.50a 2.50b err
msg
errmsg
continue continuation partial split break divide
KBCategory: kbprg kberrmsg kbprb
KBSubcategory: FxprgGeneral


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