hi,

i have a multiform application, on the Close event of each form a confirmation 
dialog is displayed. 

The user clicks a button on each form to move to the next one(or clicks a 
button to go back to the previous form), when he/she does this the current 
form's Visible property is set to false and that of the desired form is set to 
true.

When the user exits the application, Me.Close would only close the current form 
and all previous forms would remain in memory. I remember reading from the 
documentation that QUIT should not be used in GUI applications. If i close all 
previously opened forms by using FormName.Close each form's confirmation dialog 
pops up.

I've been thinking of way out of this, the only idea i've been able to come up 
with is that if there is a way a function could tell who called it, i could use 
that to prevent the confirmation dialogs from being displayed on form close. 

Say user closes Form C, now Forms A & B are have their Visible property set to 
False so they are hidden. On the Close event of Form C i call Form A,B & C's 
Close method. If Form A & B's Close method could tell that they've been called 
from another form, then maybe i could prevent the confirmation dialogs from 
popping up. Or could there be some other way to do this?

I have a attached a sample application which illustrates the problem.

Thanks in advance :)
Vikram Shankar Nair



      

Attachment: multiformClose.tar.gz
Description: GNU Zip compressed data

------------------------------------------------------------------------------
This SF.net email is sponsored by 

Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev 
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to