>Is there any way to trap the closing of a form (or form set) other than by making it non-closable and adding a "close" button? It appears that you can't return a value from the Destroy method to prevent it from proceeding, and I can't think of any other way this could be done.
Take a look at putting something in the QueryUnload method, which fires after Release but before Destroy if some action other than something invoking the Release method or a form method issuing a RELEASE command triggers shutdown - issuing a NODEFAULT prevents the form from unloading. The ReleaseType property is set before the QueryUnload fires, clicking the close control on the form sets ReleaseType to 1, so that's trappable. I've never used this approach to prevent things from happening, but the controls and properties are still intact before the code in Destroy fires...