Leventcos21
Technical User
Hi, I have an option box that will filter a combobox in a subform. I am getting an error Jet engine could not find the table tblGroupSet with matching field(s) 'Groupset'
Code:
Private Sub grpGroupType_AfterUpdate()
Me!sfrmTitle.Form.cboGroupSet.Value = Null
Me!sfrmTitle.Form.cboGroupSet.Requery
On Error Resume Next
Dim strCodeType As String
Select Case grpGroupType.Value
Case 1
strCodeType = "1"
Case 2
strCodeType = "2"
End Select
Me!sfrmTitle.Form.cboGroupSet.Value = "Select tblGroupSet.GroupSetNo, tblGroupSet.GroupSetName " & _
"FROM tblGroupSet " & _
"WHERE tblGroupSet.GroupTypeNo = '" & strCodeType & "' " & _
"ORDER BY tblGroupSet.GroupSetName;"