3

I'd like to find out which colours are used for a particular pallette in the ASP.NET Chart control.

I already know there is an enum on the Chart class to set the palette, e.g.

myChart.Palette = ChartColorPalette.Berry;

But I'd like to know which colours belong to the palette.

Before anyone asks - as I know you will - the reason I need to know the colours is because I want to create my own legend outside of the chart image.

I also know that I can set my own colours on the DataPoints for the chart, but I'd rather not have to implement my own palette.

Jon Seigel
  • 12,251
  • 8
  • 58
  • 92
Oundless
  • 5,425
  • 4
  • 31
  • 33

1 Answers1

5

Check Setting Microsoft Chart Series Colors and Colors in ASP.NET

Rubens Farias
  • 57,174
  • 8
  • 131
  • 162
  • 1
    Excellent, thanks. I used the ApplyPaletteColors() method to apply the colours to the chart and then iterated over the data points to get their Color properties. – Oundless Nov 25 '09 at 11:07