I use this on the OnError event of a form.. What I want this to do is check the Initials field for a value.. If it’s null I’m trying to use the custom message box instead of the Access one.. This code keeps gving me a compile error “Case else outside select case”.. Can anybody figure out why? Thanks..
Private Sub Form_Error(DataErr As Integer, Response As Integer)
Select Case DataErr
Case 3314 ‘Required field = Null
If IsNull(Me![Initials]) Then
MsgBox “Initials field is blank. You must enter data in Initials field to continue.”, vbCritical + vbOKOnly, “IDC Receipt System Message”
Response = acDataErrContinue
Case Else
Response = acDataErrDisplay
End Select
End Sub
-
Error code help..
- This topic has 2 replies, 2 voices, and was last updated 24 years, 5 months ago.
AuthorViewing 0 reply threadsAuthorViewing 0 reply threads