Hello folks, When my application is started, the user can use its various dialogs to navigate to its various forms. However, no matter on which of the application's forms the user is, when s/he switches to a different application, all forms are closed - so that the next time the user switches to my application, s/he will be presented with the main form.
I would prefer if the application could remember where the user was (i.e., on which form) and get him/her back there automatically when the application is switched to again. How do I do that? Now, the reason why it is the main form that appears when the application is started, is because on AppStop I call FrmCloseAllForms. I have to, or there are memory leaks. In addition, when the application is started (i.e., on sysAppLaunchCmdNormalLaunch), I do FrmGotoForm (kMainForm) before entering the event loop. I suppose I could achieve the effect I want (remembering the form the user was on the last time the application was running), by remembering the current form in the application's preferences on exit and then doing FrmGotoForm to the remembered form before entering the event loop. (Correct?) That would be fine, if the navigation between all forms was done only via FrmGotoForm. However, some of the forms are opened via FrmPopupForm - and when they are closed, my application does FrmReturnToForm from them. Wouldn't things get screwed up if I go to them directly via FrmGotoForm (instead of via FrmPopupForm) on application launch? In addition, some of the forms that are popped up are smaller than the underlying forms - so the underlying forms have to be visible, too. How should I solve this problem? Check, on startup, whether the form that has to be restored is one of those that are popped up and, if this is the case, do a FrmGotoForm to the underlying form (and should I also do FrmInitForm or anything else for it?), and immediatly do FrmPopupForm to the form that has to be popped up? Regards, Vesselin -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
