Suppressing NotInList msg in ComboBox [** RESOLVED **]
Hi all.
This one is bugging me ... I'm running Access 2000 and have a form that I want to allow adding of an account number thru the NotInList event of the combobox. That all works fine BUT! when I return from the routine that adds the acct # and refreshes the combobox the blasted default "Not in list " message still pops up even tho I have my own custom message box ... Any ideas of what I'm missing or got out of sequence?
Here's my event procedure:
PHP Code:
Private Sub AccountComboBox_NotInList(NewData As String, Response As Integer)
Dim MsgVal As VbMsgBoxResult
MsgVal = MsgBox(NewData & " is not a recognized account number. Do you wish to add it?", vbYesNo, "System Monitor")
If MsgVal = vbYes Then
Response = acDataErrAdded
CheckThisAccountNumber (NewData)
NewData = ""
AccountComboBox_AfterUpdate
Exit Sub
Else
AccountComboBox.SelStart = 0
AccountComboBox.SelLength = Len(CustomerComboBox)
End If
Response = acDataErrContinue
End Sub
Thanks for taking a look ...
- Mike