Hello,
how can I change the fill color of the boxes in a line chart legend?
I have a line chart with 3 lines, each with a different color. Of course I want that colors in the legend as well. At the moment only one color is used for all three boxes.
Where does the legend get the fill color for the boxes from?
Thanks in advance and best regards,
Gerald
the Legend gets the fill color from a variety of places, depending on the settings of the Chart color model and other color settings on the chart like the Overrides collection and the Series.PEs collection(s). the colors should match your chart, unless you are doing some custom stuff to re-color the lines. if that's the case, you could handle ChartDrawItem to find the Box primitives in the Legend (evaluate primitive.Path.IndexOf("Legend") to see if it's a legend item) and re-color the boxes there.