Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Valid vs. LostFocus
Message
 
To
09/04/2003 01:52:01
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00775350
Message ID:
00775369
Views:
15
Ric,

The purpose of these two events are as follows;

Valid = is used to determine if the focus will be allowed to leave a control
LostFocus = is used to react to the fact that focus is leaving the control

For example, the code in the Valid event of a textbox will determine if the value in the control is acceptable, once the Vlaid determines that the value is valid the LostFocus decides where focus should go from here.

There is a similar relationship between When and GotFocus;

When = is used to determine if focus will be allowed into the control
GotFocus = is used to react to the fatc that focus is arriving at the control

For example, the when code may be used to test for certain conditions that will allow the control to be used, the GotFocus will set up the circumstances for the control to receive focus and do its job.
Previous
Reply
Map
View

Click here to load this message in the networking platform