I’m using custom ScheduleViewDragDropBehavior and I would like to do the validation on Drop. For this I need my ViewModel, so I tried to create ICommand dependency properties on my custom drag-drop behavior and bind them to the corresponding properties in the ViewModel. I have problem it seems that ScheduleViewDragDropBehavior is NOT a DependencyObject. I managed to get ViewModel using:
var scheduleView = state.ServiceProvider.GetService<IObjectEditor<IAppointment>>()
And than scheduleView.DataContext property.
This is workaround is it possible to bind ScheduleViewDragDropBehavior to the ViewModel?
Thanks for help.