General information
Category:
Forms & Form designer
Michel,
when I have 2 depending forms I always instantiate the "son" as a property of the parent form
thus closing the parent form also closes the child form (as it goes out of scope)
Arnon
>My ON SHUTDOWN is calling the oApp.Cleanup() method in order to scan all opened forms and act upon a decision. When everything is ok, all forms are being terminated. This has been used since 2 years. Now, I have a situation where the ON SHUTDOWN is part of a special situation.
>
>I have a form having a filter button which is calling the filter form. When the filter form is running, the user is doing the ON SHUTDOWN. All the forms on the desktop are terminated. However, when it is done from the filter form this is causing an error where the table is not opened because the filter button of the first form that called the filter form is doing some process after the DO FORM FILTER. So, even if all the close method of the form has been called, I will still can an error here because Visual FoxPro will continue to execute the code of the Click() method of the filter button which is then dealing with a table.
>
>To solve this situation, I have put a validation to oApp.lQuit in the filter command button object. However, I don't want to have to remember to do this for any other situation that may occur like that in the future. How can I do it from the oApp.Cleanup() level in order to avoid the continuation of the Click() method of that button?
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only