I have a set of cascading combo boxes. This deals with the first one and using the limit to list and On Not In List Event.
When an item is entered into the field not in the list I am having it execute the below code. I receive the "Not in list error" when selecting yes in the below message. Can someone point me in the correct direction on making this MS error not appear?
Thanks in advance.
When an item is entered into the field not in the list I am having it execute the below code. I receive the "Not in list error" when selecting yes in the below message. Can someone point me in the correct direction on making this MS error not appear?
Code:
Private Sub cbmfg_NotInList(NewData As String, Response As Integer)
DoCmd.SetWarnings False
Me.cbMfg = ""
Dim strMsg As String, strTitle As String
strMsg = "The Manufacturer you have entered is not found in the list. Would you like to add this manufacturer?"
strTitle = " Manufacturer Not Available In List."
If MsgBox(strMsg, vbQuestion + vbYesNo, strTitle) = vbYes Then
DoCmd.OpenForm "frmNewMfg"
DoCmd.GoToRecord , , acNewRec
Else
DoCmd.CancelEvent
End If
End Sub
Thanks in advance.
Last edited: