TeeChart ASP .Net: Adding Multiple Series to same Chart
Posted: Mon Mar 16, 2015 11:41 am
We are working on Web Version of TeeChart (ASP .Net). We need to add multiple series to same chart dynamically on button click.
But while adding the second series it replaces the first series?
Here is the sample code that we used:
protected void Button1_Click(object sender, EventArgs e)
{
AddSeries();
}
private void AddSeries()
{
Steema.TeeChart.Styles.Line lineSeries1 = new Steema.TeeChart.Styles.Line();
ch1.Series.Add(lineSeries1);
lineSeries1.FillSampleValues();
count++;
lineSeries1.Title = "Line " + count.ToString();
ch1.Axes.Bottom.Labels.Angle = 90;
}
But while adding the second series it replaces the first series?
Here is the sample code that we used:
protected void Button1_Click(object sender, EventArgs e)
{
AddSeries();
}
private void AddSeries()
{
Steema.TeeChart.Styles.Line lineSeries1 = new Steema.TeeChart.Styles.Line();
ch1.Series.Add(lineSeries1);
lineSeries1.FillSampleValues();
count++;
lineSeries1.Title = "Line " + count.ToString();
ch1.Axes.Bottom.Labels.Angle = 90;
}