I still say make your own alerts in this case. Modal forms. If you find an easier/more effective way, I'm interested.
-----Original Message----- From: Rob Mermans [mailto:[EMAIL PROTECTED] Sent: Friday, August 18, 2000 5:08 AM To: Palm Developer Forum Cc: [email protected] Subject: RE: Change text on Alerts First of all ... Yes I want to change these texts at run-time. I'm well aware of the fact that you can change the window title with FrmSetTitle and change the button texts with CtlSetLabel (I do it all the time in my normal forms) but.... this requires me to have a FormPtr and I only have an Alert ID. Now how do I get from Alert ID to a FormPtr ? I've tried several things like GetFormPtr and passing the Alert ID instead of a Form ID but that doesn't seem to work. Maybe a code snippet would be helpfull ? Thanx in advance, Rob Mermans Software Engineer Mountside Software Engineering > -----Original Message----- > From: Ken Krugler [mailto:[EMAIL PROTECTED] > Sent: Thursday, August 17, 2000 17:31 > To: [EMAIL PROTECTED] > Cc: [email protected] > Subject: Re: Change text on Alerts > > > At 12:00am -0700 00-08-17, Palm Developer Forum digest wrote: > >Subject: Change text on Alerts > >From: Rob Mermans <[EMAIL PROTECTED]> > >Date: Wed, 16 Aug 2000 10:44:56 +0200 > >X-Message-Number: 180 > > > >Hello, > > > >I'm working on an app that supports multi-language. > > Do you mean your app is localized into multiple languages, or you > have to be able to switch between languages at run-time? I'm assuming > the latter, otherwise it's just a build problem/resource file > management issue. > > >I'm using the default Alerts from Constructor and changing > the messages by > >using FrmCustomAlert and > >the ^1 ^2 ^3 trick. I also want to change the text on the > buttons and the > >text on the title of the alert. > >All this has to be done on the fly and I'd rather not make > all the alerts in > >all the languages. > > > >Any ideas on how to do this ? > > FrmSetTitle is the easy way to set the alert title. If you're OK with > having fixed width buttons, then you can call CtlSetLabel to change > the button text. Note that both of these calls "grab" the string > pointer you pass in, so you have to make sure the localized string > data sticks around for the duration of the alert. > > Another option is to have separate PRCs with contain the localizable > resources, one for each language. At launch time, open the > appropriate PRC based on the language the user has selected. This > adds the PRC to the top of the resource DB chain, so subsequent calls > to FrmCustomAlert (assuming you pass a valid resource ID) will work > just fine. > > -- Ken > > Ken Krugler > TransPac Software, Inc. > <http://www.transpac.com> > +1 530-470-9200 > -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/ -- For information on using the ACCESS Developer Forums, or to unsubscribe, please see http://www.access-company.com/developers/forums/
