I have a form with an unbound field as my lookup.
[CODE=vb]Private Sub txtToShip_After Update()
Dim strFilter As String
strFilter = "[toship] like " & Chr$(39) & "*" & Forms!frmDataEn try!txtToShip & "*" & Chr$(39)
DoCmd.ApplyFilt er , strFilter
Forms!frmDataEn try!txtToShip = ""
End Sub[/CODE]
This code works but I need to be able to alert the user that there were multiple results returned. I have a textbox for this purpose, I'm not sure how to turn the visibility on when multiple results were returned or off when there is only one result. Any ideas?
[CODE=vb]Private Sub txtToShip_After Update()
Dim strFilter As String
strFilter = "[toship] like " & Chr$(39) & "*" & Forms!frmDataEn try!txtToShip & "*" & Chr$(39)
DoCmd.ApplyFilt er , strFilter
Forms!frmDataEn try!txtToShip = ""
End Sub[/CODE]
This code works but I need to be able to alert the user that there were multiple results returned. I have a textbox for this purpose, I'm not sure how to turn the visibility on when multiple results were returned or off when there is only one result. Any ideas?
Comment