1
Answer

Multiple instance of application startup form.

ratn_patil

ratn_patil

20y
2.8k
1
Application Tools :Pocket PC 2003 , WINCE.NET , .NET CF , VC# My startup form has 6 buttons ..each allowing user to jump to next screen. Also every other screen returns to startup screen. When I execute the application & navigate thru. Every time i see a new instance of my startup form created at background. i.e, when i leave my startup screen that particular instance doen't get closed/disposed. My project requirements doesn't allow me to do FindWindow and DestroyWindow. Could anyone suggest me why it is happenning and how to control it. Thanks, Ratna
Answers (1)
0
cannadbt

cannadbt

NA 6 0 20y
If your startup screen contains your main method, you will not be able to dispose it without killing your application. Windows Mobile doesn't close programs when they're "closed". They are simply minimized so the next time they are loaded they load faster. The device settings will show an instance of each form created running in the background. In order to dispose a form you will need to override the Form.OnClosing event handler and place a Dispose() call in there. I hope that is what you're talking about. cannadbt www.obtechcorp.com