Thanks Rajesh...You solved my problem :)
>Hi Sivaprasad,
Thank you for using Syncfusion products.
I have applied different colors for up and down trend in line chart. Please refer to the following code snippet.
[ C# ]
void series1_PrepareStyle(object sender, ChartPrepareStyleInfoEventArgs args)
{
ChartSeries series = sender as ChartSeries;
if (series != null&& args.Index < series.Points.Count -1)
{
if (series.Points[args.Index].YValues[0] == series.Points[args.Index+1].YValues[0])
args.Style.Interior = new Syncfusion.Drawing.BrushInfo(Color.White );
else if (series.Points[args.Index].YValues[0] < series.Points[args.Index+1].YValues[0])
args.Style.Interior = new Syncfusion.Drawing.BrushInfo(Color.Red);
else
args.Style.Interior = new Syncfusion.Drawing.BrushInfo(Color.Green );
}
}
Also kindly take a look at the attached sample.
http://websamples.syncfusion.com/samples/Chart.Windows/F60362/main.htmPlease let me know if you have any queries.
Regards,
Rajesh C