Multiple series from TChartGalleryPanel
Posted: Thu Mar 22, 2007 4:09 pm
I'm using a TChartGalleryPanel to provide a user with a list of chart types to selected, then using that to graph multiple rows of data. Each row of data is its own series, so I need to create a series for each row.
The first call to TChartGalleryPanel1.SelectedChart[0] or TChartGalleryPanel1.GetASeries() works fine, but I need multiple instances of the same series 'type'. There is a GetSeriesClass() method, but it is undocumented - is that what I should be using?
I'm sure that there should be a simple way to do this but:
...doesn't work. There's probably some way in Delphi to do the same thing that you would do in Java:
...but I'm not sure if that's what I should be doing in this case or there is some other TChart method that I should be using.
Thanks for any help that you can give.
The first call to TChartGalleryPanel1.SelectedChart[0] or TChartGalleryPanel1.GetASeries() works fine, but I need multiple instances of the same series 'type'. There is a GetSeriesClass() method, but it is undocumented - is that what I should be using?
I'm sure that there should be a simple way to do this but:
Code: Select all
series := TChartGalleryPanel1.SelectedChart[0];
newseries := series.Create(self);
chart.AddSeries(newseries);
Code: Select all
newseries := series.Clone();
Thanks for any help that you can give.