App.Exec Method | |
Start the event handling loop for the application.
Namespace:
VO
Assembly:
VOGUIClasses (in VOGUIClasses.dll) Version: 2.19
Syntax VIRTUAL METHOD Exec(
kExecType,
uObject
) AS USUAL CLIPPER
[ClipperCallingConventionAttribute(new string[] { ... })]
public virtual Usual Exec(
Usual kExecType = default,
Usual uObject = default
)
Request Example
View SourceParameters
- kExecType (Optional)
- Type: Usual
The type of event handling loop to start, specified as one of the following constants
Constant | Description |
---|
EXECNORMAL |
Tells the system to continue to execute the application until either the user closes it
(by selecting the Close menu command or using the standard Windows accelerator Alt+F4)
or the application decides to close by deliberately invoking the App:Quit() method.
When the application terminates, the thread of control exits from App:Exec() to the
next statement in your code. This is the default.
|
EXECWHILEEVENT |
Tells the system to continue to execute the application only while there are still events queued.
Once the system has dispatched the last event in the queue, the thread of control exits from App:Exec().
This gives you the opportunity to do some processing and then start another event loop by invoking
App:Exec() again. You should use this mechanism when you want to do some background processing
while the application is idle.
|
- uObject (Optional)
- Type: Usual
The object (usually a dialogwindow) for which to process the message
Return Value
Type:
Usual
A value of 0 indicates normal termination (no errors). A non-zero value indicates abnormal termination.
Remarks
Normally, the event handling loop for the application continues looping until there are no more EventContext objects. It can also terminate upon calling App:Quit().
Tip |
---|
Make sure that you show at least one window object before calling App:Exec(). |
See Also