PRB: Choosing Close from File Menu Doesn't Close Open Database

ID: Q130824

The information in this article applies to:

  • Microsoft FoxPro for Windows, versions 2.6 and 2.6a

SYMPTOMS

You cannot close an open table in a work area by choosing Close from the File menu. According to the message displayed in the FoxPro message bar, the Close option "Closes the front-most file." Logically, that would seem to also include an open table in the current work area, but even during a browse of a table only the browse or top-most active window is closed.

According to the FoxPro version 2.6 documentation:

   "Close closes the frontmost file. You can also close a window by
   double-clicking on the Control-menu box in the upper-left corner
   of the window." (FoxPro User's Guide, p. U2-22)

WORKAROUND

There are two ways to close a table in a work area:

  • Select the work area by choosing View from the Window menu. Select the table to be closed, and click the Close button.

    -or-

  • Use commands in the Command window to close a table or tables. For example, given that n1 is a work area, use the following commands to close all open databases in all work areas:

    SELECT n1 USE CLOSE DATABASES

STATUS

This behavior is by design.

MORE INFORMATION

Steps to Reproduce Behavior

1. In FoxPro, open a table in any work area.

2. Open the Command window, and choose View from the Window menu.

3. Choose Close from the File menu. The currently active window closes.

4. Repeat this process until all open windows are closed. At this point,

   The Close option on the File menu is no longer available.

Additional reference words: FoxWin 2.60 2.60a KBCategory: kbother kbdocerr KBSubcategory: FxotherGeneral


Last Reviewed: June 27, 1995
© 1999 Microsoft Corporation. All rights reserved. Terms of Use.