What I can suggest you is to call the Confirm method through Dispatcher, this way you will avoid the explained behavior. Please try the code snippet below:
if ((e.DialogViewModel is AppointmentDialogViewModel))
{
e.Cancel = true;
this.Dispatcher.BeginInvoke(new Action(Confirm));
}
}
Hope this helps.
Regards,
Kalin
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely. Sign up for Free application insights >>