Date/ format function...

pablavo

Registered User.
Local time
Today, 08:09
Joined
Jun 28, 2007
Messages
189
Hi folks.

I'm having a bit of bother with the MSCAL.Calendar.7. If you know what the calandar perhaps you know the problem.

I'm using the calandar to get the dates for an input form which will open a report.

I have code within the command button to open the report which is:

If Not IsNull(Me![txtEndDate]) Then
where = where & " AND [DateToFinance] between #" + _
Me![txtStartDate] + "# AND #" & Me![txtEndDate] & "#"
Else
where = where & " AND [DateToFinance] >= #" + Me![txtStartDate] _
+ " #"
End If


When I type the short date into the text boxes it works and the report opens. when I use the Calandar it apears as short date as well "11/11/2007" however, I'm getting a mismatch error 13. I can only presume the code is using a different date format or something? I'm not really sure on how I would use the format function in the code if this is the case.

Can anyone advise?

thanks
 

Users who are viewing this thread

Back
Top Bottom