Hi Every Body
I have an Easy question for some of you Experts, so Please excuse me.
Here is the Scenario.
I have a Form, which is made of 2 Text Boxes, Text Box A and B, I want to stop the Operation or not to be able to close my Form when ever the Subtraction of the Values of my 2 Text Boxes are not equal to Zero, The Following should work But I just can not make work for me for now:
Private Sub Form_Close()
If A.Value - B.Value <> 0 Then
MsgBox ("The Entries are Not Equal")
Select Case Err.Number
Case 3219 'operation not allowed``
End select
End If
End Sub
Could some one let me know what is it that I am doing wrong?
Best Regards
Sanan
I have an Easy question for some of you Experts, so Please excuse me.
Here is the Scenario.
I have a Form, which is made of 2 Text Boxes, Text Box A and B, I want to stop the Operation or not to be able to close my Form when ever the Subtraction of the Values of my 2 Text Boxes are not equal to Zero, The Following should work But I just can not make work for me for now:
Private Sub Form_Close()
If A.Value - B.Value <> 0 Then
MsgBox ("The Entries are Not Equal")
Select Case Err.Number
Case 3219 'operation not allowed``
End select
End If
End Sub
Could some one let me know what is it that I am doing wrong?
Best Regards
Sanan