View Full Version : Filters in Macros


PSchutz
08-22-2001, 10:34 AM
I am writing a macro that will take an input value (text box) from a user, and find all records that meet that parameter. My macro has 2 lines:

OpenTable
ApplyFilter (The filter is a query I created that filters on the input parameter.)

No matter what I have tried, I am still getting the Enter Parameter Value dialog box when the macro gets to the ApplyFilter command.

How do I automate so that I do not get the dialog box and it automatically accepts my user's input value?

Thank you in advance for your help. I am sure this is probably something very simple that my dense brain is overlooking!!

rabatwork
08-30-2001, 11:07 AM
This is a technique which I used to have a combo box provide an argument for a query - - thanks to the great programmers on this BB... It may help.

"You need to make a form that displays the combobox. You can then run the query from a button or the double click event of the combobox. The query would refer to the combobox field to get its parameter value.
Select ...
From YourTable
Where YourField = Forms!YourFormName!YourComboBoxName;"
Good luck