Donaldupnorth
10-09-2006, 04:12 PM
I have 2 forms open. 1 is hidden. I want to close it from the 2nd form but am not doing to well at it. Any help would be appreciated.
Thank You,
Donald
Thank You,
Donald
unload 2nd formDonaldupnorth 10-09-2006, 04:12 PM I have 2 forms open. 1 is hidden. I want to close it from the 2nd form but am not doing to well at it. Any help would be appreciated. Thank You, Donald reboot 10-09-2006, 04:38 PM Unload Form1 Donaldupnorth 10-09-2006, 05:21 PM Thank you for your quick response. I have tried that but when I close the 2nd program with the Red X in the right hand top of the form the Task Manager still shows the program running. When I start the 2nd program in the form load part after I get some information from the first program I use Unload Form1 but it appears to still be running. Thank You Donald passel 10-09-2006, 05:28 PM Form1 can't be unloaded if it has code running, or you have a reference to something on the form you're referencing from Form2. I don't know, but I would suspect anything declared as Public in the form, might keep if from being unloaded, but I would have to test that. Edit: Well, I've checked, and according to the Forms collection, Form1 is unloaded, even with Public variables. The Public variable maintains its value, even with the form unloaded. The program exits fine when I close the second form. I suspect you must have some kind of loop running, but not knowing the code, it is only guessing. Donaldupnorth 10-09-2006, 05:35 PM I think you are right about variables being public. I will try to work around this one. Thank You, Donald passel 10-09-2006, 05:44 PM Note, I did check (see my edits above). Public variables don't seem to be an issue in my quick test. Donaldupnorth 10-09-2006, 05:49 PM I quess I am going to have to learn about molules and how they work. Thank You, Donald |
EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum