Thank you Rajesh J --- In [email protected], "Tracy Spratt" <[EMAIL PROTECTED]> wrote: > Sorry, no easy way right now. Your approach is the correct one. Here > is a link to an example: > > http://www.cflex.net/showfiledetails.cfm?ObjectID=229 > > Tracy > > -----Original Message----- > From: [email protected] [mailto:[EMAIL PROTECTED] On > Behalf Of Rajesh Jayabalan > Sent: Wednesday, September 07, 2005 3:21 PM > To: [email protected] > Subject: [flexcoders] combobox set selection > > Hi, > > I am populating a combobox (say terms from database) now even the > selected id (The data column) is stored in the database. Is there any > easy way to set the selected item using the id or do I need to create > a function which goes thru the dataprovider and then get the selected > index and set it. > > My code is as follows > > <mx:ComboBox id="terms" > dataProvider="{termsSrv.result.mrTerms.status}" width="150"/> > > the result of termsSrv looks like > > <?xml version="1.0" encoding="utf-8" ?> > <mrTerms> > <status label="Net 30" data="1" /> > <status label="American Express" data="2" /> > </mrTerms> > > and I have the selected data as "2" what do I need to do so that the > combobox will selected "American Express" > > Regards > Rajesh J > > > > > > > -- > Flexcoders Mailing List > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt > Search Archives: > http://www.mail-archive.com/flexcoders%40yahoogroups.com > Yahoo! Groups Links
------------------------ Yahoo! Groups Sponsor --------------------~--> Fair play? Video games influencing politics. Click and talk back! http://us.click.yahoo.com/T8sf5C/tzNLAA/TtwFAA/nhFolB/TM --------------------------------------------------------------------~-> -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/

