Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to keep cursor in field till data input is correct?
Message
From
12/02/2000 20:36:00
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00331251
Message ID:
00331430
Views:
15
>Now I have another question... I may want to let the user leave the field that I'm validating with incorrect data _if_ they are hitting the "cancel" button.

Make sure you set the Cancel buttons Cancel property to .T.

Then, in your Valid(), put:
if lastkey() = 27
	return .t.
else
	&&Normalcode
endif
because if you press a cancel button, it makes the last key equal to hitting the escape key.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform