private async void ExecuteRunExtendedDialog(object o) { //let's set up a little MVVM, cos that's what the cool kids are doing: var view = new SampleDialog { DataContext = new object() }; //show the dialog var result = await DialogHost.Show(view, "RootDialog", ExtendedClosingEventHandler); //check the result... Console.WriteLine("Dialog was closed, the CommandParameter used to close it was: " + (result ?? "NULL")); }
private async void ExecuteRunExtendedDialog(object o) { //let's set up a little MVVM, cos that's what the cool kids are doing: var view = new SampleDialog { DataContext = new object() }; //show the dialog var result = await DialogHost.Show(view, "RootDialog", ExtendedClosingEventHandler); //check the result... Console.WriteLine("Dialog was closed, the CommandParameter used to close it was: " + (result ?? "NULL")); }