Forms Help

vbnewbie

Newcomer
Joined
Mar 22, 2003
Messages
1
Location
Mesa, Arizona
Please help. (Yes this is homework) The coding for my project is going well except, I cannot find a satisfactory answer for one thing: I need to code a button to load a second form while completely closing the original. Please point me in the right direction for research into the proper coding. Any help would be appreciated. Thx. vbnewbie.
 
It sounds to me like you need to use sub main instead of setting your startup object as a form. This way the main message loop will not be "destroyed" when you close the original form.
 
Attched you'll find an example on how to do it, remeber to change the properties of your project to use the Sub Main, if you don't do it when you close Form1 your application will end

Regards
 
BTW PSU_Justin's example is OK when you are hiding the Form, but in my example you can dispose Form1
 
Back
Top