J
Junior
focus doesn't return to [txtDob] if the field is null -
instead, focus advances to the next field
what is wrong with this code- or- what should i be looking for?
Private Sub txtDOB_Exit(Cancel As Integer)
If IsNull(Me!txtDOB) Then
MsgBox "Input is required in this field", vbOKOnly
Me.txtDOB.SetFocus
End If
End Sub
instead, focus advances to the next field
what is wrong with this code- or- what should i be looking for?
Private Sub txtDOB_Exit(Cancel As Integer)
If IsNull(Me!txtDOB) Then
MsgBox "Input is required in this field", vbOKOnly
Me.txtDOB.SetFocus
End If
End Sub