Thread: Two Combo Box help
10-24-11, 10:38 #1Registered User
- Join Date
- Oct 2011
Unanswered: Two Combo Box help
I have two combo boxes that help filter the results to what I need. The first one selects the facility number. Once the facility number is selected it is then possible to select which sub roof you want to select. When you select the sub roof then all information regarding that roof shows up. I am unsure on how to get it to do that. I am familiar with VBA and other tools.
Also, some the facility numbers, list as multiples. So if there are 7 subroofs associated with facility 271 it shows 271 seven times. How do I get it to show only once?
Last edited by Erenagh; 10-24-11 at 11:04.
10-25-11, 20:06 #2Moderator
Provided Answers: 19
- Join Date
- Jun 2005
- Richmond, Virginia USA
The concept is called "cascading comboboxes" although the exact same thing applies to Listboxes with the MultiSelect Property set to None, and the code is interchangeable. Here are a couple of links with examples:
Access Tips: Cascading Lists for Access Forms
Cascading Combo/List Boxes - Microsoft Access / VBA
If you Google the term along with the "Access" you'll probably get a gazillion hits!
As to only showing one of each facility number, you need to use DISTINCT with that Combobox Rowsource.
Linq ;0)>Hope this helps!
The problem with making anything foolproof...is that fools are so darn ingenious!
All posts/responses based on Access 2003/2007