GanttChartMappings.DurationFieldName Property
Gets or sets the data source field (of the TimeSpan type) that specifies a task’s duration (only work hours).
Namespace: DevExpress.XtraGantt
Assembly: DevExpress.XtraGantt.v20.2.dll
NuGet Package: DevExpress.Win.Gantt
Declaration
[DefaultValue("")]
[DXCategory("Mappings")]
[XtraSerializableProperty]
public string DurationFieldName { get; set; }
Property Value
Type | Default | Description |
---|---|---|
String | String.Empty | The data source field that specifies a task’s duration. |
Remarks
The DurationFieldName
property specifies the name of the data field that stores the duration for each task. The data field should contain values of the TimeSpan type.
Duration, Work Week Schedule, and Schedule Modes
Note that a task’s duration is the time taken to complete a task. This duration specifies only work hours. Note also that when the control reschedules a task in Auto mode, it takes into account the task’s duration and the work week schedule.
For example, the work day lasts 8 hours. If a task lasts 8 hours, it takes one work day to complete; if a task lasts 16 hours, it takes two work days to complete. That is why a 24-hour task (one day when counted in days) in the figure below takes three full work days to complete.
In Manual mode, the control does not take into account the work week schedule — all times are considered work times. In this mode, a 24-hour task takes exactly 24 hours to complete.