What Changed
In v21.1, we changed TargetFramework of the DevExpress.ExpressApp.Scheduler assembly for .NET Core WinForms from netcoreapp3.0
to netstandard2.0
. This resulted in the following changes to the API:
Property | Property type in previous versions | Property type in v21.1 |
---|---|---|
SchedulerListEditor.OptionsCustomization | SchedulerOptionsCustomization | object |
SchedulerListEditor.DateNavigator | DevExpress.XtraScheduler.Native.IDateNavigatorControllerOwner | object |
IModelListViewScheduler.SchedulerViewType | DevExpress.XtraScheduler.SchedulerViewType | DevExpress.ExpressApp.Scheduler.SchedulerViewType |
Reasons for Change
We introduced these changes for easier maintenance, clearer dependencies, and future code extension of .NET Core/.NET 5 apps and corresponding NuGet packages. These changes also help simplify common development tasks such as sharing Class Libraries with .NET Standard dependencies and cross-platform scheduler APIs across different Target Frameworks (learn more). We received lots of feedback from early .NET Core/.NET 5 adopters interested in these scenarios.
Impact on Existing Apps
This change may affect your application if you're using these properties for scheduler control customization. In this case, you may need to perform an additional cast. The following example demonstrates how to modify your existing code:
C#// in .NET Framework projects
((IModelListViewScheduler)model).SchedulerViewType = DevExpress.XtraScheduler.SchedulerViewType.Day;
schedulerListEditor.OptionsCustomization.AllowInplaceEditor = UsedAppointmentType.All;
schedulerListEditor.DateNavigator.StartDate = DateTime.Now;
// in .NET Standard and .NET Core projects
((IModelListViewScheduler)model).SchedulerViewType = DevExpress.ExpressApp.Scheduler.SchedulerViewType.Day;
((SchedulerOptionsCustomization)schedulerListEditor.OptionsCustomization).AllowInplaceEditor = UsedAppointmentType.All;
((IDateNavigatorControllerOwner)schedulerListEditor.DateNavigator).StartDate = DateTime.Now;
Visual Basic' in .NET Framework projects
DirectCast(schedulerModel, IModelListViewScheduler).SchedulerViewType = DevExpress.XtraScheduler.SchedulerViewType.Day
schedulerListEditor.OptionsCustomization.AllowInplaceEditor = UsedAppointmentType.All
schedulerListEditor.DateNavigator.StartDate = Date.Now
' in .NET Standard and .NET Core projects
DirectCast(schedulerModel, IModelListViewScheduler).SchedulerViewType = DevExpress.ExpressApp.Scheduler.SchedulerViewType.Day
CType(schedulerListEditor.OptionsCustomization, SchedulerOptionsCustomization).AllowInplaceEditor = UsedAppointmentType.All
DirectCast(schedulerListEditor.DateNavigator, IDateNavigatorControllerOwner).StartDate = Date.Now
If you encounter breaking changes or unaddressed scenarios, please contact us in the Support Center. Thank you in advance.