Legend Symbols with Gantt-Series

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Woehr.Mi
Newbie
Newbie
Posts: 38
Joined: Mon Jun 23, 2008 12:00 am

Legend Symbols with Gantt-Series

Post by Woehr.Mi » Thu Jan 15, 2009 2:44 pm

Hello,

I have 6 Gantt-Series created. All Series are displayed correctly in WebChart, but in the Legend of the WebChart (Version 3.5.3274.30663) I can not see any Symbol - only the SeriesTitle of my Gantt-Series. The Legends Symbol.Visible-Property is set to TRUE.

How can I show the Symbols (with the Color of the Gantt-Series) in Legend?

Best regards.
Michael

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 Jan 15, 2009 3:00 pm

Hi Michael,

This is most likely because, by default, Gantt series has ColorEach property set to true. Therefore each Gantt bar in a series has a different color and there's no specific color to be assigned to legend symbols. Setting ColorEach to false solves the problem, for example:

Code: Select all

		public Form1()
		{
			InitializeComponent();
			InitializeChart();
		}

		private void InitializeChart()
		{
			tChart1.Aspect.View3D = false;

			for (int i = 0; i < 6; i++)
			{
				Steema.TeeChart.Styles.Gantt gantt1 = new Steema.TeeChart.Styles.Gantt(tChart1.Chart);

				gantt1.FillSampleValues();
				gantt1.ColorEach = 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

Woehr.Mi
Newbie
Newbie
Posts: 38
Joined: Mon Jun 23, 2008 12:00 am

Post by Woehr.Mi » Thu Jan 15, 2009 3:07 pm

Hi, Narcís.

thanks! Now it works the way I want.

Best regards
Michael

Post Reply