I think you may have to iterate for the Child nodes but try
ArrayUtil.toArray(xmldata.items.item);


----- Original Message ----
From: M.Javed <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Sunday, January 27, 2008 7:26:56 AM
Subject: [flexcoders] XML to ArrayCollection

Hi,
 
I have to convert from XML or XMLList to ArracyCollection. I have found an 
example but its not working, example is pasted below,
------------ --------- --------- --------- --------- --------- --------- 
--------
<mx:ArrayCollection id="myAC" source="{xmldata. items.item} "/>

The value for source is the name of the model (xmldata), the name of the XML's 
root node (items in this example) and the child node that the array will be 
based on (item).
------------ --------- --------- --------- --------- --------- --------- 
--------
I am doing exactly the same thing but its giving runtime error "cannot convert 
XMLList to Array".
 
Any idea how to achive that?? or I have to manually Iterate on each node of XML 
to fill the array.???



Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. 



      
____________________________________________________________________________________
Be a better friend, newshound, and 
know-it-all with Yahoo! Mobile.  Try it now.  
http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ 

Reply via email to