Hi,
I need to give individual color to each bars based on the Yvalue. I tried with the below mentioned code, but it does not work.
ID given to radchart is RadChartTest
foreach (Telerik.Charting.ChartSeriesItem item in RadChartTest.Series[0].Items)
{
double val = item.YValue;
if (val >= -2 && val <=3)
{
item.Appearance.FillStyle.MainColor = System.Drawing.Color.Red;
}
else if (val < -2)
{
item.Appearance.FillStyle.MainColor = System.Drawing.Color.Blue
}
}
Regards
Vishwanath Y R
I need to give individual color to each bars based on the Yvalue. I tried with the below mentioned code, but it does not work.
ID given to radchart is RadChartTest
foreach (Telerik.Charting.ChartSeriesItem item in RadChartTest.Series[0].Items)
{
double val = item.YValue;
if (val >= -2 && val <=3)
{
item.Appearance.FillStyle.MainColor = System.Drawing.Color.Red;
}
else if (val < -2)
{
item.Appearance.FillStyle.MainColor = System.Drawing.Color.Blue
}
}
Regards
Vishwanath Y R