Skip to main content
A newer version of this page is available. .

DataSource.DateTimeSavingMode Property

Gets or sets the conversion type required before storing the appointment dates. This is a dependency property.

Namespace: DevExpress.Xpf.Scheduling

Assembly: DevExpress.Xpf.Scheduling.v19.2.dll

Declaration

public DateTimeSavingMode DateTimeSavingMode { get; set; }

Property Value

Type Description
DateTimeSavingMode

A DateTimeSavingMode enumeration value specifying the appointment storing mode.

Available values:

Name Description
Appointment

Do not convert Start and End appointment values before storing them in the data source.

Storage

Convert Start and End appointment values to the time zone of the SchedulerControl before storing them in the data source.

Utc

Convert Start and End appointment values to UTC before storing them in the data source.

Remarks

Use the DateTimeSavingMode property to relate the appointment start and end data with the same time zone.

Note

All-Day appointments (the AppointmentItem.AllDay property is True) has the DateTime.Kind value set to DateTimeKind.Unspecified for their SchedulerItemBase.Start and SchedulerItemBase.End values, even if the DateTimeSavingMode property is DateTimeSavingMode.Utc. This behavior is correct because all-day appointment occurs on a certain day disregarding local - UTC time conversions.

Set the DateTimeSavingMode property to the DateTimeSavingMode.Storage to store appointments in the Scheduler time zone (specified by the SchedulerControl.TimeZone property). Setting the property to the DateTimeSavingMode.Appointment value saves appointments to the data source with the time zone, defined by the SchedulerItemBase.TimeZoneId property.

Tip

Set the DateTimeSavingMode to the DateTimeSavingMode.Utc value in your applications to make the DateTime data consistent throughout different databases used in your applications.

See Also