We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Gantt chart with multiple "label lines"

Thread ID:

Created:

Updated:

Platform:

Replies:

115792 Feb 6,2014 08:44 AM Feb 10,2014 09:32 PM Windows Forms 1
loading
Tags: Chart
Gerda Diteriha
Asked On February 6, 2014 08:44 AM

Hi
 
I am creating Gantt chart and want to have quite bigger "header" than just a date.
 
Firstly I added week numbers instead of seperated dates.
 
 
How can I center them for a cell. Now they are right above vertical line.
Now I also want a Month name JUST ONCE ceneterd above all week numbers
Similarly I want the year above the month names, also cenetered are written only once
 
Is it possible to add label in multiple layers like this?


Gantt_bfbc2200.zip

Anandaraj T [Syncfusion]
Replied On February 10, 2014 09:32 PM

Hi Gerda Diteriha,

Thanks for using Syncfusion products.

We suggest you to use grouping labels for displaying axis labels in multiple lines.

Please refer the following code snippet to achieve this.
<code>
[CS]
            //Grouping label for multiple layers
            ChartAxisGroupingLabel cagl = new ChartAxisGroupingLabel(new DoubleRange(dt.ToOADate(), dt.AddDays(3).ToOADate()), "Quarter1");                       
            this.chartControl1.PrimaryXAxis.GroupingLabels.Add(cagl);
</code>

For your convenience, we have created a simple sample with grouping labels and it can be downloaded from the below link.

For more information about grouping labels, please refer our online documentation in the following link:
Grouping Labels

Please let us know if you have any concern.

Regards,
Anand

Attachment: Gantt_Chart_a62c1826.zip

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;