1 Reply Latest reply on Mar 19, 2013 1:15 AM by mjoshi

    About HTTPService Result


      Hi Friends,


      I have an HTTPService that I am having problem trying to use the returned data. I have a ColdFusion Component that returns the data in an XML format.


      When I use dataProvider="{objService.lastResult.projdata.datarows}" it works fine and the linechart shows data.


      But, when I try to use the returned data in the 'result' event with an event handler, the chart is blank. Can anyone tell me what might be going wrong? My code in the result handler looks like this


      <mx:ArrayCollection id = "acProjData" source="{ArrayUtil.toArray(event.result.projdata.datarows)}"/>


      The variable 'acProjData' has already been declared as a bindable variable using



      private var acProjData:ArrayCollection;


      I am not very much familar with Flex 4.5 programming. I am just trying to learn it and hoping to get my prototype working. Thanks.

      - Milind Joshi

        • 1. Re: About HTTPService Result
          mjoshi Level 1

          Answering my own question:


          I changed the line


          <mx:ArrayCollection id = "acProjData" source="{ArrayUtil.toArray(event.result.projdata.datarows)}"/>


          to this


          acProjData = event.result.projdata.datarows as ArrayCollection;


          Now my chart shows the data.

          - Milind