How do I run a report on various parameter queries?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have limited knowledge of MS Access. I am trying to create a form where I
can have criteria entered (varied criteria from a bunch of drop down boxes).
I need to be able to enter all this criteria and then run a query and have it
produce a report based on the criteria selected.
 
You can use the references to the Controls on the Form as the Parameters for
the Query being used as the RecordSource for the Report.

For example, you can set the criteria in the Query SQL like:

SELECT * FROM [YourTable]
WHERE ([frg_FactoryID] = Forms!frmCriteria!cboFactoryID)

When you open the Report, Access will replace the Parameter
"Forms!frmCriteria!cboFactoryID" with the value it can find in the ComboBox
cboFactoryID of the Form "frmCriteria".
 
Back
Top