Can you not just set resultFormat="array" for your call? Then you could avoid the toArray() method all together and it would work properly whether you returned 1 row or 100.
David --- In flexcoders@yahoogroups.com, "jlentz2112" <[EMAIL PROTECTED]> wrote: > > Hi, > > I've got a servlet returning data from a db query. I use for example > psd.lastResult.psn.row as the source for my datagrid. If I get > multiple row returned, then the psd.lastRestult.psn.row is an > ArrayCollection and I use .toArray() when I set source for the > creation of my local ArrayCollection. However, when the query returns > 1 or less rows, it is returned as an Array, so I don't want to use the > .toArray() method. Is there a way to check and see if > psd.lastResult.psn.row is an Array or an ArrayCollection? Any help > would be greatly appreciated. > > Thanks, > > jelentz > -- 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/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/flexcoders/join (Yahoo! ID required) <*> To change settings via email: mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] <*> 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/