PRB: _WRAP=.T. and ?CHR(9) Cause FoxPro to Scroll Endlessly

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

SYMPTOMS

If _WRAP = .T. and the command ?CHR(9) is issued, FoxPro for Windows will scroll in a continuous loop. The CHR(9) control code is equivalent to pressing the TAB key. FoxPro for Windows will continue to tab on the desktop unless CTRL+ALT+DEL is pressed or the computer is rebooted.

RESOLUTION

Instead of using ?CHR(9), you can use the KEYBOARD '{tab}' command.

MORE INFORMATION

The _WRAP command contains a logical value that determines whether output automatically word wraps. By default, _WRAP is set to .F. When _WRAP is set to .T., output from the ? command that would extend beyond the right margin automatically wraps to the left margin.

To demonstrate this behavior, make sure the FoxPro logo or any kind of text is on the screen and then issue _WRAP=.T. followed by ?CHR(9) in the Command window. The logo or text will scroll off the screen. If you press CTRL+ALT+DEL, you will be returned to Windows, but the memory that FoxPro used will not be released after FoxPro quits. To verify this behavior, choose About Program Manager from the Help menu. To make this memory available again, you must quit and restart Windows.

Steps to Reproduce Behavior

WARNING! CLOSE ALL APPLICATIONS BEFORE FOLLOWING THIS PROCEDURE. This procedure will cause FoxPro to loop endlessly.

In the Command window, issue these commands:

   _WRAP=.T.
   ?CHR(9)

To exit the loop, press the CTRL+ALT+DEL key combination.


Additional reference words: FoxWin 2.50 2.50a 2.50b exit infinite endless
KBCategory: kbprg kbprb
KBSubcategory: FxtoolGeneral


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.