private async void Edit_Click(object sender, RoutedEventArgs e) { FrameworkElement senderElement = sender as FrameworkElement; Room room = senderElement.DataContext as Room; RoomViewModel.Room = room; RoomContentDialog pd = new RoomContentDialog(RoomViewModel); ContentDialogResult cdr = await pd.ShowAsync(); }
private async void AppBarButton_Tapped(object sender, TappedRoutedEventArgs e) { RoomViewModel.Room = new Room(); RoomContentDialog pd = new RoomContentDialog(RoomViewModel); ContentDialogResult cdr = await pd.ShowAsync(); }