When the Application Wizard (5.0) creates a new project, it creates an application wizard object called cApplication
, subclassed from the wzApplication
object in the Appwiz.vcx library. When the application runs, the main program (projname.prg) creates an instance of the application wizard object cApplication
, then calls its methods to control the application.
The application wizard object contains code for standard methods, and includes a set of new methods.
The following new methods are defined for the wzApplication
and cApplication
objects.
Application Wizard Object Customized Methods
Event | Description |
DestroyEvent | Clears events and restores the environment. |
InitEvent | Saves the environment and resets the list of application forms. |
The following new methods are defined for the wzApplication
and cApplication
objects.
Application Wizard Object New Methods
Event | Description |
BeforeReadEvents | Contains any procedure that should be executed before the application's READ EVENTS loop is started. The default is to do nothing. |
ClearEvents | Clears any pending read events. |
DoForm | Executes a form. |
DoLabel | Executes a label. |
DoMenu | Executes a menu. |
DoProgram | Executes a .prg, .app, or .exe program. |
DoReport | Executes an .frx report. |
FileNotFoundMsgBox | Displays a File Not Found message box. |
GetCaption | Returns the caption of the application. |
GetIcon | Returns the icon of the application. |
OnShutDown | Confirms with a message box that the user wants to exit Visual FoxPro. |
ReadEvents | Starts read events mode after performing any initialization procedure. |
RefreshFormsCollection | Refreshes the list of the application's forms from collection arrays and counters. |
Release | Releases the application. |
ReleaseForm | Releases specific form or all active forms from memory. |
ReleaseForms | Releases all application forms from memory. |
ReleaseFormsCollection | Releases all forms listed in collection arrays and counters. |
ResetFormsCollection | Clears the list of the application's forms in collection arrays and counters. |
RestoreEnvironment | Restores the application's caption and icon. |
SaveEnvironment | Saves the application's caption and icon into custom properties. |
SetCaption | Sets the caption of the application's main window. |
SetIcon | Sets the icon of the application. |
Show | Displays the application's startup menu and form. |