Page 1 of 1
Clear All Series method
Posted: Mon Dec 08, 2008 8:48 pm
by 9334475
Hi,
To clear all series in a chart I frequently use
for i:=0 to Chart1.SeriesCount-1 do Chart1.Clear;
Is there some analog of that code like
Chart1.ClearAllSeries;
regards,
odissey1
Posted: Tue Dec 09, 2008 1:13 am
by 8574101
You can use Chart1.RemoveAllSeries() .
Posted: Tue Dec 09, 2008 2:05 am
by 9334475
8574101 wrote:You can use Chart1.RemoveAllSeries() .
I want to keep and re-use series for a new data. 'RemoveAllSeries' wipes off all existing series.
Posted: Tue Dec 09, 2008 12:16 pm
by narcis
Hi odissey1,
I'm afraid not, such method doesn't exist. You should use Clear in a loop as you already do.
Posted: Tue Dec 09, 2008 6:54 pm
by 9334475
narcis wrote:Hi odissey1,
I'm afraid not, such method doesn't exist. You should use Clear in a loop as you already do.
I suspected that. I typically have 5-6 charts in the project each having several series. Every time I reload data all charts need to be 'reset' so such procedure would be useful.
Please consider this for a wishlist.
Posted: Wed Dec 10, 2008 9:05 am
by narcis
Hi odissey1,
Yes, I have added this to the wish-list.