Rpt totals of datediff field only if checkbox of another field che

  • Thread starter Thread starter AndyG
  • Start date Start date
A

AndyG

How do we still keep all the data of the report on the report, but perhaps in
the footer put a total of a calculated field (datadiff), and only total the
days if another field is checked?
For example we have startdate, enddate, red, blue, green, etc. fields. Our
report will show data on all records, however, in the footer we would like
see: if they are red then display the sum of the calulation of the
DateDiff("d",[startdate],[enddate]) for each of the red detail records. In
like fashion, if blue then display the sum of the calulation of the
DateDiff("d",[startdate],[enddate]) for each of the blue detail records. All
while keeping all the records we had before?
 
I just wanted to post before many people reply. Thank God we got the code we
needed to do this. FYI:

Red_Days: IIf([red]=-1,DateDiff("d",[startdate],[enddate]))

Thanks
 
Back
Top