Hello,
I would like to programatically remove all the tools which have been added to a chart. My current code is;
i = 1
While i <= (.Tools.Count - 1)
.Tools.Delete(i)
i = i +1
Wend
This code appears to work most of the time and then other times it will error, I cannot find the source of the fault. Any advice?
My project creates and formats the chart area and series at runtime through code.
When the user requests a new chart, the chart space is formatted again.
What would be handy is a command which will reset the TChart back to it's original state as it sits on the form in the IDE, does such a command work?
Kind Regards
Anthony
Delete all Tools through Code
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Anthony,
Such a method doesn't exist. However it is on our wish-list to be considered for inclusion in future releases. To clear all tools in a chart the easiest way is using Clear method:
Such a method doesn't exist. However it is on our wish-list to be considered for inclusion in future releases. To clear all tools in a chart the easiest way is using Clear method:
Code: Select all
Private Sub Command1_Click()
TChart1.Tools.Clear
End Sub
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |