0 Replies Latest reply on Jun 1, 2007 11:47 AM by nxadave

    DataGrid population from Web Service

    nxadave
      I have a web service that I am trying to populate a Datagrid from the response but seem to have issues doing so. I have tried changing the service to give me back the data in 2 ways:

      1: When I run this one I get "EST,GL,OFSP,..." on one line of Col1 in the Grid and the same for the data on Col2
      Here's the Flex code:
      <mx:datagrid dataprovider="{myservice.GetPricingOne.lastResult}">
      <mx:columns>
      <mx:datagridColumn headerText="Col1" dataField="Value" />
      <mx:datagridColumn headerText="Col2" dataField="Description" />
      <soap-env:Body>

      And here's the SOAP response:
      <GetPricingOneResponse xmlns=" http://www.myserver.com/soapservice/xsd1">
      <Value>EST</Value>
      <Value>GL</Value>
      <Value>OFSP</Value>
      <Value>EQRP</Value>
      <Value>MAT</Value>
      <Value>CONS</Value>
      <Value>ENG</Value>
      <Value>MAN</Value>
      <Value>MTR</Value>
      <Value>R&amp;D</Value>
      <Value>STFAUG</Value>
      <Value>OT</Value>
      <Description>Estimate</Description>
      <Description>General Labor</Description>
      <Description>Office Supplies</Description>
      <Description>Equipment Replacement</Description>
      <Description>Materials</Description>
      <Description>Construction</Description>
      <Description>Engineering</Description>
      <Description>Maintenance</Description>
      <Description>Master</Description>
      <Description>Research &amp; Development</Description>
      <Description>Staff Augmentation</Description>
      <Description>Other</Description>
      </GetPricingMethodCodesAtomResponse>
      </soap-env:Body>
      </soap-env:Envelope>

      2: For this I use the same Flex code just referenceing a different Operation and get nothing in the Grid

      Here's the SOAP response:
      <soap-env:Body>
      <GetPricingTwoResponse xmlns=" http://www.myserver.com/soapservice/xsd1">
      <GetPricingTwoResult>
      <PricingMethodCode>
      <Value>EST</Value>
      <Description>Estimate</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>GL</Value>
      <Description>General Labor</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>OFSP</Value>
      <Description>Office Supplies</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>EQRP</Value>
      <Description>Equipment Replacement</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>MAT</Value>
      <Description>Materials</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>CONS</Value>
      <Description>Construction</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>ENG</Value>
      <Description>Engineering</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>MAN</Value>
      <Description>Maintenance</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>MTR</Value>
      <Description>Master</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>R&amp;D</Value>
      <Description>Research &amp; Development</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>STFAUG</Value>
      <Description>Staff Augmentation</Description>
      </PricingMethodCode>
      <PricingMethodCode>
      <Value>OT</Value>
      <Description>Other</Description>
      </PricingMethodCode>
      </GetPricingMethodCodesResult>
      </GetPricingMethodCodesResponse>
      </soap-env:Body>
      </soap-env:Envelope>