3 Replies Latest reply on Nov 13, 2009 12:20 PM by msakrejda

    Chart duplicating Series results in too many legend items

    c3eb4 Level 1

      I've created an item for this on bugs.adobe.com - https://bugs.adobe.com/jira/browse/FLEXDMV-2258


      My client requires this in order to finish the application I am working on so I'm hoping someone has a workaround or suggestions for me.


      The forum would not allow me to attach my jpg and mxml file but they are available on the bug url above


      Copied from the bug:

      My application has a collection of machines, each of which has the same properties. I want to graph those properties, but organize them by dates (the values of the properties are different for different days). So the y axis items are dates, and each date has a cluster of machines. Each date has the same number of machines and each machine has the same properties. The issue I'm having is that I want each property (in the example there are 3 properties, represented by BarSeries) to have the same color for each machine in each cluster. So overall, there should only be 3 colors and the legend should have 3 items. Instead, the chart creates different colors for each machine (represented by a BarSet), so there are 3 (machines/BarSets) times 3 (properties/BarSeries) which gives 9 colors and 9 items in the legend. I'm looking to have 3 colors and 3 items in the legend. I was hoping there would be a property on BarSet or BarChart to specify to share BarSeries among the BarSets rather than it forcing unique instances of BarSeries for the BarSets. I tried storing just 3 instances of BarSeries (one for each property) and assigning each BarSet.series property to the stored array of BarSeries, but the outcome was that it would only display one item for each cluster rather than 3.


      Thank you for any suggestions!