Yep. That would be no problem. But I want to do other stuff like set a title based on a combination of the result fields. It also bugging me that I cannot get a handle on something pretty basic :)
--- In [email protected], "Matt Chotin" <[EMAIL PROTECTED]> wrote: > > So why not take that array collection that worked and assign to the > DataGrid? That's what DataGrid expects now. > > > > Matt > > > > ________________________________ > > From: [email protected] [mailto:[EMAIL PROTECTED] On > Behalf Of yaagcur > Sent: Wednesday, November 02, 2005 8:06 AM > To: [email protected] > Subject: [flexcoders] problem adapting to FLEX 2 on defining variables > > > > I had the following working OK in FLEX 1.5 > > <mx:Script> > <![CDATA[ > var gridResult:Object > > function getPlayersResultHandler(result):Void { > > gridResult=result; > // other stuff > } > > ]]> > </mx:Script> > > <mx:DataGrid dataProvider="{gridResult}"> > > However I am finding it impossible to duplicate in FLEX2/AS3 > > I have tried various alternatives e.g > [BINDABLE] > public var myTest:Object - which gives me a "no type declaration" error > > Placing the variable within the resulthandler gives an "access of > undefined property" error (predictably I suppose) in the <mx:DataGrid> > > The data is coming across OK because if I alternatively do > <mx:ArrayCollection id="gridResult" > source="{mx.utils.ArrayUtil.toArray(ContactService.getPlayers.result)}" > /> > I can populate fine > And also putting breakpoints in the resulthandler I get debug results > e.g > result=[](0x6c5c746) > [0] Object > FULLNAME="Joe Blow" > > > > > > -- > Flexcoders Mailing List > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt > Search Archives: > http://www.mail-archive.com/flexcoders%40yahoogroups.com > > > > > SPONSORED LINKS > > Web site design development > <http://groups.yahoo.com/gads?t=ms&k=Web+site+design+development&w1=Web+ > site+design+development&w2=Computer+software+development&w3=Software+des > ign+and+development&w4=Macromedia+flex&c=4&s=126&.sig=ynjozILdtUiijfLjiz > 5l1Q> > > Computer software development > <http://groups.yahoo.com/gads?t=ms&k=Computer+software+development&w1=We > b+site+design+development&w2=Computer+software+development&w3=Software+d > esign+and+development&w4=Macromedia+flex&c=4&s=126&.sig=i_RMdAMzxP1R8fB7 > NcnaqQ> > > Software design and development > <http://groups.yahoo.com/gads?t=ms&k=Software+design+and+development&w1= > Web+site+design+development&w2=Computer+software+development&w3=Software > +design+and+development&w4=Macromedia+flex&c=4&s=126&.sig=4g8hODKyQov1GX > OxaXG2Sg> > > Macromedia flex > <http://groups.yahoo.com/gads?t=ms&k=Macromedia+flex&w1=Web+site+design+ > development&w2=Computer+software+development&w3=Software+design+and+deve > lopment&w4=Macromedia+flex&c=4&s=126&.sig=hhODNnONza_qi3x2OWe-Qg> > > > > > > > > ________________________________ > > YAHOO! GROUPS LINKS > > > > * Visit your group "flexcoders > <http://groups.yahoo.com/group/flexcoders> " on the web. > > * To unsubscribe from this group, send an email to: > [EMAIL PROTECTED] > <mailto:[EMAIL PROTECTED]> > > * Your use of Yahoo! Groups is subject to the Yahoo! Terms of > Service <http://docs.yahoo.com/info/terms/> . > > > > ________________________________ > ------------------------ 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/

