You just have to put id in you data grid.. and after you can use "dataprovider" ... like ..
if your dataGrid is named " dataGrid" you use : dataGrid.dataprovide = Array VAr... Inside your array var you have the names of the items.. and your data Grid labels have to have the same names! 2010/4/8 jakir qureshi <[email protected]> > Hi Pradp, > > this is simple parsing hope this help you. > > var loader:URLLoader = new URLLoader(); > loader.addEventListener(Event. >> >> COMPLETE, loadXML); >> loader.load(new URLRequest(“content.xml”)); >> > > >> function loadXML(e:Event):void >> { >> > var colsMetaDataArrC:ArrayCollection= new ArrayCollection(); > >> xml = new XML(e.target.data); >> trace(xml); >> > > for each(var cxmlData:XML in e.result) > { > > for each(var metaDataXml:XML in xmlData.data) > { > var metaDataObj:Object = new Object(); > metaDataObj.name = [email protected](); > metaDataObj.dataType = [email protected](); > metaDataObj.label = [email protected](); > metaDataObj.date= [email protected](); > colsMetaDataArrC.addItem(metaDataObj) > } > } > >> } > > > > > > > On Thu, Apr 8, 2010 at 7:51 AM, pradp <[email protected]> wrote: > >> Hi gurus >> >> I have been breaking my head since 2 days on how to populate date from >> an xml file to an advanceddatagrid using actionscript 3. >> >> I could see the below code to load the xml file >> >> var loader:URLLoader = new URLLoader(); >> loader.addEventListener(Event.COMPLETE, loadXML); >> loader.load(new URLRequest(“content.xml”)); >> >> function loadXML(e:Event):void >> { >> xml = new XML(e.target.data); >> trace(xml); >> } >> >> Converting the xml object to an ArrayCollection I am not sure how to >> do that. Once I get the ArrayCollection object, I could populate the >> date to the datagrid. >> >> Please help me if any of you have a solution for this. >> >> Thanks >> Pradp >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Flex India Community" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]<flex_india%[email protected]> >> . >> For more options, visit this group at >> http://groups.google.com/group/flex_india?hl=en. >> >> > > > -- > Thanks & Regards > > Jakir M. Qureshi > Software Engineer > > -- > You received this message because you are subscribed to the Google Groups > "Flex India Community" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<flex_india%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/flex_india?hl=en. > -- You received this message because you are subscribed to the Google Groups "Flex India Community" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/flex_india?hl=en.

