Hi!
In one of my tables I have an attribute called "descripton", which is a description of a particular item.
One example is
"Colonial cedar bookcase".
Is there anyway I can use user input to filter a query (or preferably a report using the "where" function in macros)? I want the user to be able to input "cedar" and have all records containing "cedar" in the descripton field appear.
__1. You cannot open a Query within a Macro and specify a WHERE Clause.
__2. You can open a Report within a Macro and specify a WHERE Clause in the following manner:
[fieldname] = Forms![formname]![controlname on form] __3. Why not create a Parameter Query and have the User set the criteria within the Query. e.g. in the Criteria cell of Description
[Enter Description]. You can now run the Query from a Macro. You can also set the Record Source of a Report to this Query then open the Report from a Macro bypassing the WHERE Clause.