G
Guest
In a form, I have a combo box for "segment". Once the segment is selected by
the user, they then click on "fgroup" and the fgroup combo box list shows
them only the fgroups pertaining to the selected segment. My problem is that
the "fgroup" list box is supposed to have 2 columns: (1) Fgroup_ID and (2)
Fgroup, and only the Fgroup is showing up after the segment is selected. I'm
sure I need something related to the "Fgroup_ID" in my code, but I don't know
what. Here's what I have so far:
'After the user selects a Segment, it limits the list of Fgroups to only
those applicable
'to the selected Segment.
Private Sub cboSEGMENT_AfterUpdate()
On Error Resume Next
cboFGROUP.RowSource = "Select tPRODUCT_FGROUP.FGROUP " & _
"FROM tPRODUCT_FGROUP " & _
"WHERE tPRODUCT_FGROUP.SEGMENT = '" & cboSEGMENT.Value & "' " & _
"ORDER BY tPRODUCT_FGROUP.FGROUP_ID;"
End Sub
the user, they then click on "fgroup" and the fgroup combo box list shows
them only the fgroups pertaining to the selected segment. My problem is that
the "fgroup" list box is supposed to have 2 columns: (1) Fgroup_ID and (2)
Fgroup, and only the Fgroup is showing up after the segment is selected. I'm
sure I need something related to the "Fgroup_ID" in my code, but I don't know
what. Here's what I have so far:
'After the user selects a Segment, it limits the list of Fgroups to only
those applicable
'to the selected Segment.
Private Sub cboSEGMENT_AfterUpdate()
On Error Resume Next
cboFGROUP.RowSource = "Select tPRODUCT_FGROUP.FGROUP " & _
"FROM tPRODUCT_FGROUP " & _
"WHERE tPRODUCT_FGROUP.SEGMENT = '" & cboSEGMENT.Value & "' " & _
"ORDER BY tPRODUCT_FGROUP.FGROUP_ID;"
End Sub