Stupid Date Question

2007-06-15 Thread Robert Harrrison
I validate dates all the time, but in this case I have to combine three separate fields and validate if the date is valid. code is: cfif IsDate(form.day/form.month/form.year) is false BAD DATE /cfif Anyone see what's wrong here. It's not validating. Robert B. Harrison Director

RE: Stupid Date Question

2007-06-15 Thread Dawson, Michael
) to build your date. M!ke -Original Message- From: Robert Harrrison [mailto:[EMAIL PROTECTED] Sent: Friday, June 15, 2007 3:10 PM To: CF-Talk Subject: Stupid Date Question I validate dates all the time, but in this case I have to combine three separate fields and validate if the date

Re: Stupid Date Question

2007-06-15 Thread Aaron Rouse
Did not test it but I think this would work: IsDate(#Form.day#/#form.Month#/#Form.Year#) May need to switch the placement of the day and the month. I personally would use a CreateDate function either within the IsDate function or on a variable that is then used in the IsDate function. On

Re: Stupid Date Question

2007-06-15 Thread Ariel Jakobovits
quotation marks and pound signs? - Original Message From: Robert Harrrison [EMAIL PROTECTED] To: CF-Talk cf-talk@houseoffusion.com Sent: Friday, June 15, 2007 1:09:32 PM Subject: Stupid Date Question I validate dates all the time, but in this case I have to combine three separate fields

Re: Stupid Date Question

2007-06-15 Thread Andrew Scott
How about. cfif isDefined(form.Year) and isDefined(form.Month) and isDefined( form.Day) cfif IsDate(CreateDate(form.year,form.month,form.day)) Date Valid cfelse Date is invalid /cfif /cfif On 6/16/07, Robert Harrrison [EMAIL PROTECTED] wrote: I validate dates all the time, but in

Re: Stupid Date Question

2007-06-15 Thread Alan Rother
Only one problem with this code cfif isDefined(form.Year) and isDefined(form.Month) and isDefined( form.Day) cfif IsDate(CreateDate(form.year,form.month,form.day)) Date Valid cfelse Date is invalid /cfif /cfif If the data entered into either of the three form fields is invalid, the

Re: Stupid Date Question

2007-06-15 Thread Andrew Scott
very true On 6/16/07, Alan Rother [EMAIL PROTECTED] wrote: Only one problem with this code cfif isDefined(form.Year) and isDefined(form.Month) and isDefined( form.Day) cfif IsDate(CreateDate(form.year,form.month,form.day)) Date Valid cfelse Date is invalid /cfif /cfif If the data