Please take a look at this:

enter image description here

Can i modify the default black color of the Axis ? I have searched for this and changed several properties but it is still black.

有帮助吗?

解决方案

Have you tried this, Chart would be your chart object you have created

//0 would be indice of chart area you wish to Change, Color.ColorYouWant
Chart.ChartAreas[0].AxisX.LineColor = Color.Red;
Chart.ChartAreas[0].AxisY.LineColor = Color.Red;

//To change the Colors of the interlacing lines you access them like so
Chart.ChartAreas[0].AxisX.InterlacedColor = Color.Red;
Chart.ChartAreas[0].AxisY.InterlacedColor = Color.Red;

//If you are looking to change the color of the Grid Lines
Chart.ChartAreas[0].AxisX.MajorGrid.LineColor = Color.Red;
Chart.ChartAreas[0].AxisY.MajorGrid.LineColor = Color.Red;
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top