G
Guest
Hi,
I'm trying to filter several fields in a subform, the main form contains
unbound fields which will supply the search criteria
Unfortunately I can't get past filtering more than one field, below is my
unsuccessful attempt.
Private Sub cmdFilterOn_Click()
Dim strSearch1 As String
Dim strSearch2 As String
strSearch1 = "Like '*' & cboCreatedBy.Value & '*'"
strSearch2 = "Like '*' & cboIncidentType.Value & '*'"
Form_frmHistory.Form.Filter = "[Created By]" & strSearch1 And "[Incident
Type]" & strSearch2
Form_frmHistory.Form.FilterOn = True
End Sub
Regards,
Duncan
I'm trying to filter several fields in a subform, the main form contains
unbound fields which will supply the search criteria
Unfortunately I can't get past filtering more than one field, below is my
unsuccessful attempt.
Private Sub cmdFilterOn_Click()
Dim strSearch1 As String
Dim strSearch2 As String
strSearch1 = "Like '*' & cboCreatedBy.Value & '*'"
strSearch2 = "Like '*' & cboIncidentType.Value & '*'"
Form_frmHistory.Form.Filter = "[Created By]" & strSearch1 And "[Incident
Type]" & strSearch2
Form_frmHistory.Form.FilterOn = True
End Sub
Regards,
Duncan