PRB: PAUSE Key Does Not Function in FoxPro for Windows

Last reviewed: June 27, 1995
Article ID: Q98697
The information in this article applies to:
  • Microsoft FoxPro for Windows, versions 2.5 and 2.5a

SYMPTOMS

When you are executing a program file in FoxPro for Windows, pressing the PAUSE key does not halt execution of the program. In FoxPro versions 2.0 and later for MS-DOS, pressing the PAUSE key will stop a program's execution.

CAUSE

The Windows-based version of FoxPro interprets the PAUSE key differently than the MS-DOS-based versions do. This behavior is normal for a Windows- based application.

RESOLUTION

To work around this behavior, do one of the following:

  • Assign an ON KEY LABEL WAIT WINDOW statement to a key so that it can be used to interrupt the program.
  • Press the ESC key, which brings up a warning window with options to Cancel, Ignore, or Suspend the program.

MORE INFORMATION

To reproduce this problem, create the following program and name it TEST.PRG:

   FOR A=1 TO 100000
   ? A
   ENDFOR

This program will scroll numbers down the screen. If this program is executed in FoxPro for MS-DOS, pressing the PAUSE key will halt the program; you must press the ENTER key to resume execution. In FoxPro for Windows, however, pressing the PAUSE key does not stop the program.


Additional reference words: FoxWin 2.50 2.50a
KBCategory: kbprg 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.