How do I calculate the number of days between a field date and a particular date?
P Patty Aug 18, 2009 #1 How do I calculate the number of days between a field date and a particular date?
B BruceM Aug 18, 2009 #2 You seem to be aware you would use the DateDiff function, as it is in the Subject line of your question. In a query: ElapsedDays: DateDiff("d",[Field1],[Field2]) Field1 and Field2 are generic names for the date fields. Use your actual field names. Likewise, ElapsedDays can be a name of your choice. Alternatively, as the Control Source of an unbound text box: =DateDiff("d",[Field1],[Field2])
You seem to be aware you would use the DateDiff function, as it is in the Subject line of your question. In a query: ElapsedDays: DateDiff("d",[Field1],[Field2]) Field1 and Field2 are generic names for the date fields. Use your actual field names. Likewise, ElapsedDays can be a name of your choice. Alternatively, as the Control Source of an unbound text box: =DateDiff("d",[Field1],[Field2])
D diazmaggi Dec 11, 2009 #3 Patty said: How do I calculate the number of days between a field date and a particular date? Click to expand...
Patty said: How do I calculate the number of days between a field date and a particular date? Click to expand...
K KARL DEWEY Dec 11, 2009 #4 DateDiff("d",[Date1],Date2]) But remember the the difference between 3 July 09 and 4 July 09 is one day and the difference between 3 July 09 and 3 July 09 is zero days. So you need to add one to the difference.
DateDiff("d",[Date1],Date2]) But remember the the difference between 3 July 09 and 4 July 09 is one day and the difference between 3 July 09 and 3 July 09 is zero days. So you need to add one to the difference.