Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to Check For Valid Date Before VFP
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00745078
Message ID:
00745189
Views:
69
Martin,

The user will set the date format once and not on a field by field basis.
I will then 'set date' as you suggested.
I don't want to do validation * in addition * to VFP - I want to validate
* before/instead * of VFP.
I was hoping that there was a built-in function or class that would allow me to mimic VFP date checking.


>>>SET NOTIFY OFF will stop the display of the WAIT WINDOW.
>
>>Tks. That took care of the first part.
>>Now is there an easy way for * me * to check the validity of the date considering it could be in several different format :).
>
>Hi, Allan.
>
>You can validate the value entered before the user tries to get out of the textbox in the InteractiveChange event.
>
>Anyway, I don't undestand very well what kind of validation do you try to apply over VFP's own. If you want to allow the user to enter either DD/MM/YYYY *or* MM/DD/YYYY, btake in consideration that you can't know whether "05/06/2003" means May 6th or June 5th.
>
>I think that letting the user select the format she would use trough the app is a good idea, but once she selected it, you have to SET DATE and be ask for any date value in a consistent fashion.
>
>Indeed, a good idea if many different formats are expected can be to add some behaviour to your date textbox to display a little visual indication above or bellow the field stating the date format (you can show it when the control get focus and hide it when it looses it).
>
>Hope this helps,
Regards,

Allan Coganovitch
allanc@proven-solutions.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform