This is just a wild stab in the dark, but maybe it's because FrmDoDialog sets the clipping to the popup form only, so the main form cannot undraw your control. Don't know what you want to do about it, but you could play with the clipping inside your handler or, better yet, just force the main form to redraw after the popup since you said that the controls are made unusable as expected.
Matt ----- Original Message ----- From: "Richard Coutts" <[EMAIL PROTECTED]> To: "Palm Developer Forum" <[EMAIL PROTECTED]> Sent: Tuesday, July 02, 2002 4:26 AM Subject: Re: Trouble hiding contols > My problem seems to be related to my trying to hide contols from code > within a dialog handler. I have my main form and a dialog that pops up. > When the user clicks on a button, it hides some of the controls in the main > form. > > My code to realize the dialog looks like this: > > : > FrmSetEventHandler( dialog, handler ); > FrmPopupForm( formID ); > buttonPressed = FrmDoDialog( dialog ); > FrmReturnToForm( activeID ); > : > > If I wait until "FrmDoDialog" returns to hide my controls, everything works > great. But, if I try to hide the controls before it returns, they only > become unusable. (I'm not covering the controls with the dialog, so its not > a case of the image under the dialog being restored with the image of the > hidden contols, even though they've been correctly hidden.) > > I could write a parser to queue the command until the dialog finishes, but > I'd rather not if I can avoid it. If I am diagnosing things correctly here, > can someone recommand an alternative to FrmDoDialog that will allow me to > make changes to the main from from within the Dialog's handler? > > Thanks! > Rich > > ----- Original Message ----- > > I'm trying to hide some controls using "FrmHideOject." It works okay if > the > > contols are on the currently active form. But, if I have a second form as > > the active form and am trying to hide controls in the first form, then my > > call is only succeeding in making the controls Unusable -- unfortunately > > they're still visible. The same calls seem to work fine if the form the > > controls are on is the currently active form. > > > > My code for hiding the form is pretty straight forward: > > > > FormType* formP = FrmGetFormPtr(formID); > > UInt16 index = FrmGetObjectIndex(formP, objectID); > > FrmHideObject(formP, index); > > > > Thanks in advance, > > Rich > > > > > > -- > > For information on using the Palm Developer Forums, or to unsubscribe, > please see http://www.palmos.com/dev/support/forums/ > > > > > > -- > For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ > > -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
