Page 1 of 1

FM6 need to ensure date format

PostPosted: Tue Mar 14, 2006 8:20 am
by David Fox
I have a database that requires the user to enter dates as the first of each month.

I want to set up a warning that alerts the user if they have not used the date format (UK date) 1/mm/yyyy.

I cannot see a date function in FM6 to check that this is the case. I have tried a text function to extract the first Left character but this does not seem to be the way to do it.

Sorry if this is obvious but I am stuck!

Thanks as always.

David

PostPosted: Tue Mar 14, 2006 9:00 am
by John Sindelar
Assuming they are entering a date field (not a text field) the following will evaluate true if they enter the first of the month:

Date ( month ( datefield ) ; 1 ; year ( datefield ) ) = datefield

PostPosted: Wed Mar 15, 2006 6:44 am
by David Fox
Thank you John, as always.

Best regards

David