Changing Names of Series Plots

TeeChart for ActiveX, COM and ASP
Post Reply
marathoner
Newbie
Newbie
Posts: 35
Joined: Wed Dec 12, 2007 12:00 am

Changing Names of Series Plots

Post by marathoner » Wed Mar 12, 2008 1:05 pm

When I plot a series of 2D lines, a legend in a white box is displayed. On each line in the legend, it says, "Series 0", "Series 1", "Series 2" and so on. On each line, it displays the color of the line. How do I rename the names in the legend?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Mar 12, 2008 1:10 pm

Hi marathoner,

Try using this:
m_Chart1.Series(0).SetTitle("MySeries");
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

marathoner
Newbie
Newbie
Posts: 35
Joined: Wed Dec 12, 2007 12:00 am

Post by marathoner » Wed Mar 12, 2008 6:04 pm

Thanks, that works.

Is it possible to delete a series title from the legend without deleting its points from the chart?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Thu Mar 13, 2008 10:32 am

Hi marathoner,

Yes, you need to use ShowInLegend property, for example:

Code: Select all

	m_Chart1.Series(0).SetShowInLegend(false);
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply