Combo Box: Value List limited from selection from another combo box

GraemeG

Registered User.
Local time
Today, 21:12
Joined
Jan 22, 2011
Messages
212
Hi,

I have attached the table below from which I require assistance on combo boxes.
The first combo box on the form selects the SOR shortdesc - I then want the second combo box only to show the SOR descriptions which relate to the SOR shortdesc selected in the first combo box.
Is this possible?

Thanks

SOR code SOR shortdesc SOR description
CA9613 BOLT BOLT:RENEW FIRE SECURITY BOLT. CA9615 BOLT BOLT:RENEW GLASS TO SEC.BOLT CA9619 BOLT BOLT:REMOVE; EASE AND REFIX. CA9121 CATCH CATCH:RENEW BRASS CASEMENT. CA9129 CATCH CATCH:RENEW A.A CASEMENT.
CA9137 CATCH CATCH:RENEW ZINC ALLOY CASEMENT. CA9161 CATCH CATCH:RENEW LOCKABLE CASEMENT
 
Yes it's possible. Look at "Demo4ComboA2000.mdb" (attachment, zip).
Open Form and try. Adapt it as you need.
 

Attachments

Yes it's possible. Look at "Demo4ComboA2000.mdb" (attachment, zip).
Open Form and try. Adapt it as you need.

Hi I have not got it set up like this and would take an age to split all my tables up.
I have this but the second combo box is always blank no matter what I select from the first box.

First Combo
SELECT [SORV4_BR_DPC].[SOR shortdesc] FROM SORV4_BR_DPC GROUP BY [SORV4_BR_DPC].[SOR shortdesc];

Private Sub cboFrontLoungeDPC_ShortDesc_AfterUpdate()
Me.cboFrontLoungeDPC_Description = vbNullString
Me.cboFrontLoungeDPC_Description.Requery
End Sub


Second Combo
SELECT SORV4_BR_DPC.[SOR description] FROM SORV4_BR_DPC WHERE (((SORV4_BR_DPC.[SOR shortdesc])=[Forms]![subMOT_FrontLounge]![cboFrontLounge_DPC_ShortDesc])) ORDER BY SORV4_BR_DPC.[SOR description];
 
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. In addition to MStef's example, here are a couple of links with examples:

http://www.fontstuff.com/access/acctut10.htm

http://bytes.com/forum/thread605958.html

If you Google the term along with the "Access" you'll probably get a gazillion hits!

Linq ;0)>
 
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. In addition to MStef's example, here are a couple of links with examples:

http://www.fontstuff.com/access/acctut10.htm

http://bytes.com/forum/thread605958.html

If you Google the term along with the "Access" you'll probably get a gazillion hits!

Linq ;0)>

Hi, thanks.
Sorry yes I understand the concpet and what they are. but what I have (posted just above your 1st repsonse) does not seem to be working.
Thanks
 

Users who are viewing this thread

Back
Top Bottom