GanttDateEditTimeSectionProperties.Assign(PropertiesBase) Method
Copies settings of the specified object to the current object.
Namespace: DevExpress.Web.ASPxGantt
Assembly: DevExpress.Web.ASPxGantt.v24.2.dll
Declaration
Parameters
Name | Type | Description |
---|---|---|
source | PropertiesBase | The source object. |
Remarks
If source and destination objects are instances of different PropertiesBase descendants, the Assign
method copies only the properties common to both descendants.
The example below copies time section settings between two GanttDateTimeColumn editors:
protected void Page_Init() {
// ...
GanttDateTimeColumn startDate = new GanttDateTimeColumn();
startDate.FieldName = "StartDate";
startDate.PropertiesDateEdit.TimeSectionProperties.Visible = true;
startDate.PropertiesDateEdit.TimeSectionProperties.ShowHourHand = true;
startDate.PropertiesDateEdit.TimeSectionProperties.ShowMinuteHand = true;
startDate.PropertiesDateEdit.TimeSectionProperties.ShowSecondHand = true;
GanttDateTimeColumn endDate = new GanttDateTimeColumn();
endDate.PropertiesDateEdit.TimeSectionProperties.Assign(startDate.PropertiesDateEdit.TimeSectionProperties);
endDate.FieldName = "EndDate";
Gantt.SettingsTaskList.Columns.Add(startDate);
Gantt.SettingsTaskList.Columns.Add(endDate);
}
See Also