Calculate number of days between a start date and an end date

F

franklinbukoski

I have a query that asks me for a start date and an end date. I would like
to show these two dates on a report (which I have done) along with the report
calculating the number of days between those two dates.

Can anyone assist?
 
O

Ofer

Use the datediff function

Create another field in the report, and in the ControlSource Property of the
field write
=DateDiff("d",[FieldStartName],[FieldEndDateName])

That will return the different in days.
Read help on the subject to see the different options you have using datediff
 
K

KARL DEWEY

In the query design view add to the Field row of the grid type Start: and
copy the part of your criteria prompting for the start date. You should copy
to make sure it is identical. It would look like --
Start: [Enter start date]
In another column of the Field row do the same for the end date.

The responses will be in the output of the query for use in the report.
 
Top