Solved Cascading Combo Box in nested subforms (1 Viewer)

Local time
Yesterday, 21:19
Joined
Feb 2, 2020
Messages
54
Hi,
I have received some good help in the past from various people on a project I am working on. Unfortunately I am stuck again with the following:

I have several combo boxes embedded in subforms within a navigation form. I know the syntax changes between a standalone form and one embedded as a subform in a Navigation form but I can't seem to get it right.

Using the Navigation form: "Report Center", I want the user to select the "Filter By" combo box and then only be shown the contacts that meet that criteria in the "cboFilteredContact" combo box.

Thank you for your assistance.
 

Attachments

  • TC6-Temp2.zip
    948.9 KB · Views: 77

MajP

You've got your good things, and you've got mine.
Local time
Yesterday, 21:19
Joined
May 21, 2018
Messages
8,555
Code:
Private Sub cboContact_Enter()
  If Not IsNull(Me.cboContactType) Then
    strSQL = "SELECT ID, [File As] FROM qryContactsExtended where Role = " & Me.cboContactType
    Me.cboContact.RowSource = strSQL
  End If
End Sub
 

theDBguy

I’m here to help
Staff member
Local time
Yesterday, 18:19
Joined
Oct 29, 2018
Messages
21,499
Hi. See if this does what you want...

PS. I would actually prefer MajP's approach, but I kept with yours in this one...
 

Attachments

  • TC6-Temp2 (2).zip
    953.6 KB · Views: 68
Local time
Yesterday, 21:19
Joined
Feb 2, 2020
Messages
54
Code:
Private Sub cboContact_Enter()
  If Not IsNull(Me.cboContactType) Then
    strSQL = "SELECT ID, [File As] FROM qryContactsExtended where Role = " & Me.cboContactType
    Me.cboContact.RowSource = strSQL
  End If
End Sub
Thank you!
 

Users who are viewing this thread

Top Bottom