Information générale
Catégorie:
Codage, syntaxe et commandes
Realized that no where in my app is there a ON SHUTDOWN. I have a top level form and it gets instantiated in my main.prg. Of course in tht top levelform i close all the objects and do some clean up, and then in main.prg i have a procedure CLEANUP() that is called upon returning frmo the object. Can I have ON SHUTDOWN execute CLEANUP(), or no because it is in main.prg it is out of scope if ON SHUTDOWN gets called from the toplevelform?
When does ON SHUTDOWN get executed? Does it get executed under normal program termination?
Thanks
Brenda
>At a minimum, you need to issue a CLEAR EVENTS and tell VFP to quit when the >SHUTDOWN event occurs. Add the following line to your main program:
>
>ON SHUTDOWN DO AllDone
>
>Create a .PRG named AllDone.PRG; it should look so,mething like:
>
>* AllDone.PRG
>CLEAR EVENTS
>ON SHUTDOWN
>CLOSE ALL
>CLEAR ALL
>QUIT
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement