You need to add some criteria to the query so that it only returns values equal to the one selected in the combo box.
Once a selection is made in the combo box its value is a number representing the Primary Key field of the table it is based on so you would need to add that field to your query first (so that you can then add a reference to the combo box on the form) in the criteria row of the query.
I have done this for you the query called SearchbySupp in the attached db.
However, IMHO it would be better to use the query as the data source and display the results in a form, perhaps as a subform on your main form. I would not expose a query like this to the user.
Well one way would be to have a tab control on the main form with each form on a separate tab.Thanks so much for the help! Your suggestion sounds good. But how would I go along into showing the results on main form? both the combo boxes will reference different queries so I'm not sure how two subforms will fit on the form if thats the route to take.
Is there a way to position the subforms so they don't overlap are positioned differently?
Thanks so muchWell one way would be to have a tab control on the main form with each form on a separate tab.
My personal preference would be to create the two subforms and have them both hidden. In the After Update event of each combo box you could have code to make visible the correct subform and hide the other.
Try the attached db.That sounds really neat! I know you've help me out a lot already but could you please provide an example like you did with db? I've attached an update file. I'm no coder by any means and this was pushed on to me without my input.
Try the attached db.
Post back if you have any questions.