I have a form with a macro button on it; the form is bound to a query. The intent is that the User supplies a piece of data in the field next to the macro button, and then when the User clicks the button, a macro launches that validates the data. If the value is valid, then the macro is supposed to run a query so that all records with this value are returned. The User can then use the record-selector arrows at the bottom of the form to move through the data set.
When running a query from VBA, what is the proper protocol for running a query that serves as a record source for a form? I want to run the query but not show it explicitly. Do I need to create a record set to do this, or will DoCmd.OpenQuery do what I want in the background?
Thanks for the time and consideration.
When running a query from VBA, what is the proper protocol for running a query that serves as a record source for a form? I want to run the query but not show it explicitly. Do I need to create a record set to do this, or will DoCmd.OpenQuery do what I want in the background?
Thanks for the time and consideration.