BUG: Press Key Msg When Display Structure to File Noconsole

ID: Q125416

The information in this article applies to:

SYMPTOMS

Using the DISPLAY STRUCTURE TO FILE command with the NOCONSOLE option suppresses output of the table structure to the screen, but it does not stop FoxPro from prompting you to "Press any key to continue."

CAUSE

While FoxPro does suppress the output to the screen, it acts as if output is being scrolled to the screen and prompts you to press any key when enough output to fill the screen has been sent to the file. This behavior happens when the structure of the database contains more fields that can fit on one screen. FoxPro prompts you to press a key each time the output consumes one full screen. Therefore, if you have a large database that takes three screens to display the structure you will be prompted to press any key three times.

RESOLUTION

Replace the DISPLAY command with the LIST command:

   LIST STRUCTURE TO FILE OUTPUT.TXT NOCONSOLE

This prevents the "Press any key to continue" message.

STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

MORE INFORMATION

When the command is issued from the Command window, the behavior does not usually present a problem. However when the command is issued from within a program, this behavior becomes undesirable.

Steps to Reproduce Problem

1. Create and save a database that has at least 50 fields.

2. Create and save a program that contains this line of code:

   DISPLAY STRUCTURE TO FILE OUTPUT.TXT NOCONSOLE

3. Run the program. You will be prompted to press any key.

Additional reference words: 1.00 1.10 2.00 6.00 2.50 2.50a 2.50b 2.60 buglist2.50 buglist2.50a buglist2.50b buglist2.60 KBCategory: kbprg kbdisplay kbbuglist KBSubcategory: FxprgGeneral

Last Reviewed: April 27, 1995