Task Types
BCGControlBar Pro (MFC)
BCGSuite (MFC)
BCGControlBar for .NET
The Gantt chart supports the following task types:
- Regular, which is represented by the rectangle with the task progress indication.
- A milestone is represented by a diamond shape and signifies a significant checkpoint in the project.
- The group is represented by a horizontal bar that displays the project's start and finish times.
Sample code:
// Create a regular task
COleDateTime t = COleDateTime::GetCurrentTime ();
t.SetDate (t.GetYear (), t.GetMonth (), t.GetDay ()); // reset time
CBCGPGanttItem* pItem = new CBCGPGanttItem;
pItem->SetInterval (t, t + COleDateTimeSpan(3, 0, 0, 0));
// add to Gantt
pChart->AddItem (pItem);
// Milestone
pItem = new CBCGPGanttItem;
pChart->InsertItem (3, pItem);
t -= COleDateTimeSpan (1, 12, 0, 0);
pItem->SetInterval (t, t);
// Insert a group item
pItem = new CBCGPGanttItem;
pChart->InsertItem (2, pItem);
t -= COleDateTimeSpan(3, 6, 0, 0);
pItem->SetInterval (t, t + COleDateTimeSpan(4, 12, 0, 0));
pItem->SetGroupItem (TRUE);