Prompting for Criteria already defined in Report/Query.

  • Thread starter Thread starter JackG
  • Start date Start date
J

JackG

I have a report based on a query. The query has a criteria set ('Program'
field from 'Client' Table needs to select records with crieteria of
"highroad" Or "Aftercare". The query runs fine alone and picks records from
'Client' where the 'Program' field contains "highroad" Or "Aftercare". The
report also run the query fine. When I call the report from a macro
(OpenReport) I am being prompted for the parameters for the 'Program' field?

What do I need to do. If the answer is set the With Condition on the
OpenReport macro, what is the syntax and do I remove the criteria from the
query? Table = Client, Field=Program, Values "Highroad" Or "Aftercare"
Query=Query-AllClients, Report = Report-AllClients. Please help, I have
tired everything I know and nothing is working. What is the syntax for an
expression in the With Condition of an OpenReport Macro.

I am using Access 2003.

Thanks You,
 
Condition syntax is this (using a generic name for the query's field name):

[NameOfFieldInQuery] = "Highroad" OR [NameOfFieldInQuery] = "Aftercare"
 
Back
Top