private void ShowItemData(int id) { ProductFormWindow ProductWindowWindows = new ProductFormWindow(id); ProductWindowWindows.ShowDialog(); if (ProductWindowWindows.DialogResult.HasValue && ProductWindowWindows.DialogResult.Value) { Refresh(); } }
private void AddProduct_Click(object sender, RoutedEventArgs e) { ProductFormWindow ProductWindowWindow = new ProductFormWindow(); ProductWindowWindow.ShowDialog(); if (ProductWindowWindow.DialogResult.HasValue && ProductWindowWindow.DialogResult.Value) { Refresh(); } }
private void ShowProductButton_Click(object sender, RoutedEventArgs e) { if (_viewModel.SelectedProduct != null) { //_viewModel.SelectedUser.Id ProductFormWindow ProductWindow = new ProductFormWindow(_viewModel.SelectedProduct.Id); ProductWindow.ShowDialog(); if (ProductWindow.DialogResult.HasValue && ProductWindow.DialogResult.Value) { Refresh(); } } else { MessageBoxResult result = MessageBox.Show("Para ver el detalle de un Usuario, primero selecciona un elemento de la lista", "Confirmation", MessageBoxButton.OK, MessageBoxImage.Warning); } }