Skip to main content

CalendarControlBase.EditValue Property

Gets or sets the edit value (current date).

Namespace: DevExpress.XtraEditors.Controls

Assembly: DevExpress.XtraEditors.v24.1.dll

NuGet Package: DevExpress.Win.Navigation

Declaration

[Bindable(true)]
[DXCategory("Data")]
public object EditValue { get; set; }

Property Value

Type Description
Object

The current date.

Remarks

Note

Using the EditValue and CalendarControlBase.DateTime properties makes sense in single selection mode. In multi-select mode (see CalendarControlBase.SelectionMode), the EditValue and CalendarControlBase.DateTime properties are not updated when a date range is selected.

You can bind the EditValue property (or the CalendarControlBase.DateTime property, which is in sync with the EditValue property) to a database field, and thus allow an end-user to edit this field by clicking a date in the Calendar Control. In single date selection mode (see CalendarControlBase.SelectionMode), the selected date is saved in the EditValue property.

The EditValue property is of the object type. The CalendarControlBase.DateTime property, which is in sync with the EditValue property, is of the DateTime type. When the EditValue property is set to null or to a value that cannot be converted to a valid DateTime value, the CalendarControlBase.DateTime property is automatically set to CalendarControlBase.NullDate.

If the CalendarControlBase.SyncSelectionWithEditValue option is enabled and the EditValue/CalendarControlBase.DateTime property is changed, the selection is automatically set to the new date specified by the CalendarControlBase.DateTime property.

See Also