Hello
Could someone please tell me what is wrong with my code?
Basically, if the user enters a value into a combo box which isn't in the list, I would like a message to pop up saying to select a value from the list.
I want to disable the default Access message about it...I thought I could do that with the docmd.setwarnings code?
Thanks for any help!
Could someone please tell me what is wrong with my code?
Code:
Private Sub lengthmeasureselect_NotInList(NewData As String, Response As Integer)
DoCmd.SetWarnings False
If MsgBox("Please select a value from the list.", vbOKOnly + vbInformation, "Value Not Found in the List") = vbOK Then
Exit Sub
Else
Exit Sub
End If
DoCmd.SetWarnings True
End Sub
I want to disable the default Access message about it...I thought I could do that with the docmd.setwarnings code?
Thanks for any help!