Cascading 4 combo boxes

moishy

Registered User.
Local time
Today, 18:07
Joined
Dec 14, 2009
Messages
264
Hello Experts,

I have a form that uses two cascading combo boxes (cboCity and CboStreet) to filter records in a subform.
The code I use for that is:

Code:
Private Sub cboCity_AfterUpdate()

    sfrmDonorInput.Form.Filter = "[City]= '" & cboCity & "'"
    sfrmDonorInput.Form.FilterOn = True
    Me.cboStreet = Null
    Me.cboStreet.Requery

End Sub

Private Sub cboStreet_AfterUpdate()

    If IsNull(cboStreet) = False Then
        sfrmDonorInput.Form.Filter = "[City]= '" & cboCity & "'"
        sfrmDonorInput.Form.Filter = "[Street]= '" & cboStreet & "'"
        sfrmDonorInput.Form.FilterOn = True
    End If

End Sub

So far it works fine. Now I have a need to add 2 more combo boxes (cboCivilYear and cboLocalYear) that should filter the records further. For the life of me I can't figure it out.
 
Thank you, the trouble is I'm dizzy from reading so many tuts. and yet accomplish nothing.
 
Hi Moishy,

I'm not sure if you ever got this sorted, I'm having the same problem and the above tutorials posted by jdraw are very nice but the problem is they only break it down to two combo boxes or two nodes deep, my dilemma to cascade "Campus" "Building" "Floor" "Room" you can find my Discussion on this site called "Cascading Combo Boxes 4 Nodes Deep"

Hopefully we can get an answer :-)
 

Users who are viewing this thread

Back
Top Bottom