Often when a user sees results from search string results in a combobox dropdown, a natural response is to arrow down to a result they pinpoint.
But, if my users click the down arrow, it will update the combobox, thereby not jumping to the record as expected. I'd like to limit the combobox to sense an update ONLY if the user hits "Tab", "Enter" or a Mouse click.
The combo box search that I've written otherwise works perfectly.
Here's my code in the On Key Up event
Private Sub cboGCPC_Search_KeyUp(KeyCode As Integer, Shift As Integer)
Dim strSQL As String
strSQL = "SELECT * " _
& "FROM qryGCPC_Search " _
& "WHERE [DocumentNumber] Like '*" & Me.cboGCPC_Search.text & "*' OR [Description] Like '*" & Me.cboGCPC_Search.text & "*' OR [Vendor] Like '*" & Me.cboGCPC_Search.text & "*' OR [Receiver] Like '*" & Me.cboGCPC_Search.text & "*';"
Debug.Print strSQL
Me.cboGCPC_Search.RowSource = strSQL
Me.cboGCPC_Search.Dropdown
End Sub