PDA

View Full Version : linked combo boxes to limit each other ?



bdsii
02-02-2011, 03:10 PM
Hello all.....I am still learning my way around Access and think VBA may be the required way to solve my problem. I attaching a sample Access 2007 database that illustrates simply (I hope) my questions.

I need to use a form with combo boxes to assist in a search of the table. If the user knows one of the three options, they can use the drop down to select the data they know which then limits the info under each of the other two drop-downs. The user can then choose one of the other two drop downs and select from the available options and then move to the third drop down. The data under the third drop down is limited by the selections of the first two and the user can select the final piece of the puzzle. After making their selections from the three combo boxes, the user hits a command button that opens a different form displaying the additional data from the record corresponding to the selections made on the previous form.

I have created a sample table, query tied to a form and then the form that should open when the command button is clicked. They are attached.

So.....how do you limit two combo boxes based on a selection in the third ? Plus, the user can choose any of the three combo boxes in any order they wish and not in any order.

Do I need the query I created or should the combo boxes be tied to the table directly instead ?

I would appreciate the help if anyone is willing to help answer these questions. I am still learning but cannot figure this one out.

Thanks in advance ! :-)

orange
02-03-2011, 04:21 PM
There are excellent free video tutorials at Datapig.
This is specific to 1 combobox, but there are others.
Try it.

http://www.datapigtechnologies.com/flashfiles/combobox1.html

The subject you are dealing with is Cascading Comboboxes.

bdsii
02-04-2011, 08:00 AM
Thanks for the info. The video was pretty neat and informative as I am just starting out. I think the complication of this effort is due to trying to sync the 3 comboboxes.

Can anyone help ?

RonNCmale
02-04-2011, 04:43 PM
This shows 3 combo boxes.

http://www.datapigtechnologies.com/flashfiles/combobox3.html

bdsii
02-08-2011, 09:15 AM
Thanks RonNCmale.....however the video which was helpful did not help with my issue here. After digging into this I think what I want to do is not possible, or at least it is not something that has been done often. I wanted to be able to limit combo boxes in any order....for instance, if the user selected combo box 2 and made a selection then it would limit the other two. When the user then chooses combo box 1, the choices of comb box 3 would then be limited by combo box 2 AND combo box 1.

Any ideas ?