Page 1 of 1

Chart Foregroun color

Posted: Fri Aug 25, 2006 5:51 pm
by 9790735
Is there a way to change the foreground color so that all axes, labels etc will change? I couldnt find one.

I did mange to use Chart.Axes.Bottom.AxisPen.COlor but it doesnt change the lables. If there is no global setting, how can I change the lables color? They are in Auto mode.
I tried Chart.Axes.Bottom.Lables.Color and ...Pen.Color without any luck.

thanks,

Posted: Mon Aug 28, 2006 6:52 am
by Marjan
Hi.

The following code will change all axes label font color white, axis grid color to red and axis color to blue:

Code: Select all

for (int i = 0; i < tChart1.Axes.Count; i++)
{
  Steema.TeeChart.Axis axis = tChart1.Axes[i];
  axis.Labels.Font.Color = Color.White;
  axis.Grid.Color = Color.Red;
  axis.AxisPen.Color = Color.Blue;
}