3 Replies Latest reply on Jan 23, 2011 3:49 PM by oldMster

    Need Help with XML Parsing on to DataGrid

    kiran7881 Level 1

      Hi

       

       

       

      I have retrivied  this  Data  into my HttpService Result function .


      <list>
        <User>
          <ename>JAMES</ename>
          <empno>7900</empno>
        </User>
        <User>
          <ename>FORD</ename>
          <empno>7902</empno>
        </User>
        <User>
          <ename>MILLER</ename>
          <empno>7934</empno>
        </User>
      </list>

       

      [Bindable]
          private var xmldata:XML;

      private function resultHandler(event:ResultEvent):void{
              xmldata=event.result as XML;
         }


      <mx:DataGrid x="50" y="23" width="469" height="265" dataProvider="{xmldata.User}">
        <mx:columns>
         <mx:DataGridColumn headerText="Type" dataField="ename"/>
         <mx:DataGridColumn headerText="Sales" dataField="empno"/>
        </mx:columns>
      </mx:DataGrid>

       

      But this is not displaying any data into DataGrid .

      Could anybody please help me .

      Thanks .