RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TApplication.ShowMainForm Property

Determines whether the application shows its main form on startup.

Pascal
property ShowMainForm: Boolean;
C++
__property Boolean ShowMainForm;

Use ShowMainForm to control whether and when the application shows its main form. 

The default value of true is set in the constructor. When ShowMainForm is true, the main window shows automatically when the application starts. The MainForm property specifies which form is the main form. 

To hide the main form at startup, set ShowMainForm to false in the main project file before the call to the Run method. Make sure that the Visible property of the form is also false. 

 

Create 

MainForm 

Run 

Visible 

Hiding the Main Form

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!