Page 1 of 1
Changing Names of Series Plots
Posted: Wed Mar 12, 2008 1:05 pm
by 15047739
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?
Posted: Wed Mar 12, 2008 1:10 pm
by narcis
Hi marathoner,
Try using this:
m_Chart1.Series(0).SetTitle("MySeries");
Posted: Wed Mar 12, 2008 6:04 pm
by 15047739
Thanks, that works.
Is it possible to delete a series title from the legend without deleting its points from the chart?
Posted: Thu Mar 13, 2008 10:32 am
by narcis
Hi marathoner,
Yes, you need to use ShowInLegend property, for example:
Code: Select all
m_Chart1.Series(0).SetShowInLegend(false);