The issue you are describing now is completely different than your first one.
If you are receiving error messages in the query than my guess would be
this is a form issue. Presumably you are passing information from a form
to the query that feeds the report. What you need to do is set up some data
validation on the form before launching the report (and subsequent query).
So, for example, you need to have a date in a control on the form that
will be passed to the report query. If the user enters some text or other
strange characters the query will of course have issues with this. So
behind the command button that launches the report, first do some checking
on the information the user has entered. You could test to see if it actually
is a date (or can be interpreted as one), you could see if the date falls within
a certain range, whether it is a future date, etc. You could (and should)
even check to see of the user actually entered anything as well.
Once all of your data validations pass the tests, then you open the report.
Since the report's query recordsource *should* be happy now, you will
not receive that error message. You can still use the report's OnNoData
event to close the report if no records were returned.
--
Jeff Conrad
Access Junkie - MVP
http://home.bendbroadband.com/conradsystems/accessjunkie.html
http://www.access.qbuilt.com/html/articles.html
in message: