1 Reply Latest reply on Jun 17, 2008 10:17 AM by matthew horn

    Flex Charts/DataProvider sum

    rquantin Level 1
      hi Eveyone,

      I've got a dataprovider that I apply on a pie charts, it is working but is there any way that I can automaticaly get a sum of the field I display?

      For example:

      {client:client1, project:project1, time:2}
      {client:client1, project:project1, time:2}
      {client:client1, project:project2, time:2}
      {client:client2, project:project4, time:2}
      {client:client2, project:project4, time:2}
      {client:client2, project:project5, time:2}

      I always display the field time, the pie is showing me 6 parts, which is probably normal.

      Here is the thing, is there any way I could get the sum by client or project without create actionscript code?

      to get for example, filtered by client:
      {client:client1, time:6}
      {client:client2, time:6}
      or filtered by project:
      {project:project1, time:4}
      {project:project4, time:4}

      Any sumFilter function that could take the filtered field and the field to sum? or other property that could help me?

      The real dataprovider is a lot bigger than that, It would make me able filter all this data without create an actionscript for every kind of filter I want.

      Any hints?