Patrick Downey
Patrick Downey

Reputation: 965

In Access, how can I make it so values in a ComboBox are hidden, but show up as matches in the combo box's search box?

In my database, I have a table of "Suppliers" and they have a field called Active.

In a form in MS-Access 2010, I have a bunch of fields and I have a Combo Box for selecting Suppliers. However, I would like the Suppliers who are not active to be not visible while scrolling through the possible Suppliers, but if they type in the search box a name that matches the supplier, I would like them to become visible or popup as a match.

How can I do this? I am willing to implement VBA. I apologize if I am misunderstanding Combo Boxes.

Edit: Edited the question to make a little more sense.

Upvotes: 2

Views: 447

Answers (1)

E Mett
E Mett

Reputation: 2302

If you want items of the searchlist to show up as you type they MUST be in the list.

However, you can sort the list so that the inactive ones appear at the end.

SELECT Supplier, Active FROM tblSuppliers ORDER BY Active, Supplier

Upvotes: 2

Related Questions