private void MiCategorieInserisci_Click(object sender, RoutedEventArgs e) { bool result = new WindowFormCategoria().ShowDialog().Value; if (result) { LoadCategorie(categoriaService.GetAll()); } }
private void MiCategorieModifica_Click(object sender, RoutedEventArgs e) { if (lbxCategorie.SelectedIndex == -1) { return; } Categoria l = (Categoria)lbxCategorie.SelectedItem; bool result = new WindowFormCategoria(l).ShowDialog().Value; if (result) { LoadCategorie(categoriaService.GetAll()); } }