KeithG said:So the user can select 3 tool# and the query will search every tool field and bring back matching results? Is this what you want?
Yes, up to 8 tool combo boxes to select as search criteria.
KeithG said:So the user can select 3 tool# and the query will search every tool field and bring back matching results? Is this what you want?
KeithG said:The best thing to do is stop and come up with your requirments of what you want the form to do. Then you it is much easier to design and takes alot less time.
KeithG said:Won't all of your tools be listed in the combo box also? You can do it the way you want to though. You will have to grab each value from the combo boxes and seperate them with a comma and put them into a string and then use the In(strComboList) in your where clause.
If IsNull(Me.cmbToolSearch1) = False And Len(Me.[cmbToolSearch1]) > 1 Then
If IsNull(strWhere) = False And Len(strWhere) > 2 Then
strWhere = strWhere & " AND ([Outside Tool #1]='" & Me.cmbToolSearch1 & "')"
Else
strWhere = " Where ([Outside Tool #1]='" & Me.cmbToolSearch1 & "')"
End If
End If
If IsNull(Me.cmbToolSearch1) = False And Len(Me.cmbtoolsearch) >= 1 Then
strToolSearch = strToolSearch & "'" & strToolSearch & "'" & ","
End If
If IsNull(strToolSearch) = False Then
strWhere= " Where [InsideToolNo1]In(" & strToolSearch & ")" And .....
End If
Dim strToolSearch As String