It triggers QueryUnload() event. See also the ReleaseType property.
Execute NODEFAULT to preven in it form closing.
>When using a form in VFP9, I want to capture the "mouse click" on the red "X" close button and do some testing before I allow the user to close the form.
>
>If certain things have not been done I want to warn the user that they are exiting (closing) the form without finishing these tasks and give them a "Yes / Cancel" choice. If they click on "Yes" the form would close but if they click on "Cancel" the focus would return to the form and it would not be closed.
>
--sb--