Joaj,
Dump your Exit_form property. You can use the built in ReleaseType property for this purpose. ReleaseType will contain 2 if the form is released by using the control menu or the close box (X). Your code in the valid can be;
IF Thisform.ReleaseType <> 0
RETURN .T.
ENDIF
... The rest of your valid code here