radchartview online graph

Posted by Ashokpalli under C# on 12/4/2013 | Points: 10 | Views : 2277 | Status : [Member] | Replies : 0
am working winforms using telerik control radchart am doing online graph using lineseries draw a line no problem but take every time new point draw new line my problem is old line adding line. how to new in loop runing tell me\

my code

LineSeries ls;
if (this.radChartView1.Series.Count > 0)
ls = (LineSeries)this.radChartView1.Series[0];
else
{
ls = new LineSeries();

}
dt = SEW.RepositoryADO.ChannelDataRepositoryADO.GetLast20DataPoints(ChannelName, ConString);
for (int j = 0; j < 1; j++)
{

for (int i = 0; i < dt.Rows.Count; i++)
{

ls.DataPoints.Add(new CategoricalDataPoint(Convert.ToDouble(dt.Rows[i][0].ToString())));
//CategoricalDataPoint point = new CategoricalDataPoint();
////point.Category = i;
////point.Value = dt.Rows.Count;
//ls.DataPoints.Add(new CategoricalDataPoint(Convert.ToDouble(dt.Rows[i][0]) + j, dt.Rows[i][1].ToString()));


}


this.radChartView1.Series.Add(ls);
}




Responses

(No response found.)

Login to post response