Date Comparisons

K

Ken

Hi, I hope you are doing well.

I am using a Function to compare dates in a table for calculating invoices.
I am using the following statement to compare due dates:

If Table1![Due Dte] > 8 / 10 / 2004 Then

The [Due Dte] is a defined as Date/Time in the table. Problem is when this
runs, it selects all records in the table to include records with due dates
prior to 8/10/2004. I'm guessing I'm using the wrong date comparion format or
something like that. I'd appreciate any help I can get on this.

KP
 
T

Tom Jackson

I think you want:
If Table1![Due Dte] > #8 / 10 / 2004# Then

date literals are delaminated by #
what you had was 8 divided by 10 divided by 2004

tom
 
Top