Hi,
I'm try to customize the dialog to create or edit appointments if I do a coubleclick on the schedule.
I try two approches.
1. Create a EditAppointmentDialogStyle and EditAppointmentTemplate. So the template shows the content what I want. But I can't set a custom header on the dialog over the EditAppointmentDialogStyle .
2. Create a custom ScheduleViewDialogHostFactory. Here is the problem that I can't set a custom control as a template.
protected override IScheduleViewDialogHost CreateNew(ScheduleViewBase scheduleView, DialogType dialogType) { var window = new ShiftWindowDialogHost() {
// Content = new SchedulerDialog(),
Content = ServiceLocator.Current.GetInstance<UserManagement>(),
ScheduleView = scheduleView,
Header = "What a charm" };
StyleManager.SetThemeFromParent(window, scheduleView);
return window; }
I get the exception
System.InvalidOperationException: 'SchedulerDialog' TargetType does not match type of element '.
at System.Windows.Style.CheckTargetType(Object element)