I am populating a XamChart from code. I have 3 Series that have 3 DataPoints each. The chart itself is correct, but the legend is not. Why is the legend showing all the DataPoint labels instead of the 2 series labels?
While in debug mode, I inspected the labels for both the series and DataPoints:
series[0].Label - "Proposed Budget\r\nJul 2010"
series[1].Label - "Proposed Budget\r\nAug 2010"
series[0].DataPoints[0].Label - "1-2300-6100"
series[0].DataPoints[1].Label - "1-2300-6110"
series[0].DataPoints[2].Label - "1-2300-6200"
series[1].DataPoints[0].Label - "1-2300-6100"
series[1].DataPoints[1].Label - "1-2300-6110"
series[1].DataPoints[2].Label - "1-2300-6200"
I'm attaching a screenshot of my XamChart. Note that the Legend items match the DataPoint Labels.
I figured out the issue. I had set the Series.DataPointColor = DataPointColor.Different; Removing that corrected the legend, and now my Series labels are my LegendItems.
I am having the same, Need a solution asap. Thanks.