A
Alex
I have the following code on_exit of a form control to make sure there is a
part # entered before clicking on any other control on the form. If I click
the close button while my cursor is in the Part control, the msg fires twice.
Is there a way that I can get it to only fire once when the close button is
clicked and have the form close? Thanks.
Private Sub Part__Exit(Cancel As Integer)
If IsNull(Me.Part) Then
MsgBox "You must enter a valid Part #."
Cancel = True
End If
End Sub
part # entered before clicking on any other control on the form. If I click
the close button while my cursor is in the Part control, the msg fires twice.
Is there a way that I can get it to only fire once when the close button is
clicked and have the form close? Thanks.
Private Sub Part__Exit(Cancel As Integer)
If IsNull(Me.Part) Then
MsgBox "You must enter a valid Part #."
Cancel = True
End If
End Sub