My summary report shows various record totals for YTD and Date Range entries. I was able to get a stmt to work for the Date Range fields, but not the YTD fields.
Report field = txtNoticesYTD
Source = tblWARNData
This report field is supposed to show a total of all records entered in the current year. To do this I wrote a stmt that counts the [RecordID] field in tblWARNData when YYYY in [EntryDate] = txtYYYY. (txtYYYY is formatted as "yyyy" with a control source of =Date().
=Count [RecordID] Where (Year([EntryDate]))=[txtYYYY]
But Access doesn't seem to like the "Where" operator and I can't figure out how else to write it. How can I count [RecordID] when YYYY in EntryDate = txtYYYY?
Report field = txtNoticesYTD
Source = tblWARNData
This report field is supposed to show a total of all records entered in the current year. To do this I wrote a stmt that counts the [RecordID] field in tblWARNData when YYYY in [EntryDate] = txtYYYY. (txtYYYY is formatted as "yyyy" with a control source of =Date().
=Count [RecordID] Where (Year([EntryDate]))=[txtYYYY]
But Access doesn't seem to like the "Where" operator and I can't figure out how else to write it. How can I count [RecordID] when YYYY in EntryDate = txtYYYY?