Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Messages of Validations
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00261658
Message ID:
00263778
Views:
22
Pablo,

The Valid event will fire in a combo and list object when the users makes a selection, that is changes the value. Simply tabbing through does not fire the valid on these controls.

As for an example here's a simple one. Two textboxes, one for marital status and one for spouses name. In the Valid of marital status I would ensure that the value was an acceptable one of S-Single, M-Married if it is not either S or M I would display a message and return 0 to force the user to get it right. Once the value is valid, then in the LostFocus I would look at that value and either SetFocus to the spouse's name textbox if the value is M or setfocus to another control if the value is S. Keep in mind that using a SetFocus in the LostFocus requires that you also issue a NODEFAULT command to stop VFP from automatically firing its own SetFocus.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform