Page 1 of 1

DBChart - custom colors for one series

Posted: Fri May 22, 2009 7:29 am
by 10051657
Hello,

I'm new and not experienced with TDBChart, therefore the question might be stupid, but I've a simple bar chart with one series and want to define the first 5 colors. If the chart contains more than 5 values, the other colors doesn't play a role. Could someone tell me how to do this?

Posted: Fri May 22, 2009 9:00 am
by yeray
Hi Cogito,

Once you've added the points to the series, you could do something like this:

Code: Select all

  Series1.ValueColor[0] := clGreen;
  Series1.ValueColor[1] := clYellow;
  Series1.ValueColor[2] := clRed;
  Series1.ValueColor[3] := clWhite;
  Series1.ValueColor[4] := clMaroon;