Gantt chart date update in C++
Posted: Sat Jun 11, 2016 6:50 am
i'm a newbie and i'm working on a C++ VCL project with a StringGrid and a GanttChart. What i want to do is to "update" the gantt bar automatically once a new data is entered into the StringGrid.
What i do first is to create a chart with bars with this command:
That's perfect for creating a chart but how do i update the gantt's bar date so the bar automatically resize itself? For example if the user enter 1 day, the gantt bar display only 1 day and when the user enter 5 day the gantt bar automatically "resize" itself from 1 to 5 days.
Is there any function or properties which can do this for me?
What i do first is to create a chart with bars with this command:
Code: Select all
TGanttSeries *Series1;
int i = 0;
Series1 = new TGanttSeries(this);
Series1->AddGantt(StrToDate(StringGridEd1->Cells[4][1]),StrToDate(StringGridEd1->Cells[5][1]), i,"Task"+IntToStr(i));
Series1->ParentChart = Chart1;
Is there any function or properties which can do this for me?