Hiding the Main Visual FoxPro Window

If you're running a top-level form, you might not want the main Visual FoxPro window to be visible. You can use the Visible property of the Application object to hide and show the main Visual FoxPro window as needed.

To hide the main Visual FoxPro window

  1. In the Init event of the form, include the following line of code:

    Application.Visible = .F.
    
  2. In the Destroy event of the form, include the following line of code:

    Application.Visible = .T.
    

Make sure that you also provide a way to close the form by using THISFORM.Release in some method or event.

Note   You can also include the following line in a configuration file to hide the main Visual FoxPro window: SCREEN = OFF

See Also

Creation of Single- and Multiple-Document Interfaces | Configuring Visual FoxPro | Displaying a Child Form Inside a Top-Level Form | Adding a Menu to a Top-Level Form | Creating Forms | Extending Forms with Form Sets | Addition of Objects to Forms