Column headers hierarchy

You can show multiple resources for each day:

You can show different number of resources for each day:

You can aggregate resources into groups:

You can show resource details in additional header rows:

The number of header rows is not limited, the hierarchy can show even 3 or more levels:

 

How it works:

  • It's an extension of the Resources view that can show multiple rows in the header.
  • The Column class is extended and it can contain other columns as Children.
  • The HeaderLevels property determines the number of rows in the header.

Example:

  1. Set ViewType="Resources".
  2. Set HeaderLevels="2".
  3. Generate the Columns hierarchy in Page_Load:
        DayPilotCalendar1.Columns.Clear();
        for (int i = 0; i < 3; i++)
        {
            DateTime day = DateTime.Today.AddDays(i);

            Column c = new Column(day.ToShortDateString(), day.ToString("s"));
            c.Date = day;
            DayPilotCalendar1.Columns.Add(c);

            Column c1 = new Column("A", "A");
            c1.Date = day;
            c.Children.Add(c1);

            Column c2 = new Column("B", "B");
            c2.Date = day;
            c.Children.Add(c2);

        }

This example can be found in Demo/Calendar/DaysResourcesView.aspx and in the DayPilot Pro package.

Online demo

DayPilot for ASP.NET, DayPilot for Java