private void Button_Click_6(object sender, RoutedEventArgs e) { if (BooksList.SelectedIndex == -1) { MessageBox.Show("No book selected"); return; } NewBook bookWnd = new NewBook(((BookCategory)CategoryList.SelectedItem).Id, this, ((Book)BooksList.SelectedItem).Id); bookWnd.Activate(); bookWnd.Show(); }
private void Button_Click_7(object sender, RoutedEventArgs e) { if (FilterResults.SelectedIndex == -1) { MessageBox.Show("No book selected"); return; } NewBook bookWnd = new NewBook(0, this, ((Book)FilterResults.SelectedItem).Id); bookWnd.Activate(); bookWnd.Show(); }
private void Button_Click_4(object sender, RoutedEventArgs e) { if (CategoryList.SelectedIndex == -1) return; NewBook bookWnd = new NewBook(((BookCategory)CategoryList.SelectedItem).Id, this); bookWnd.Activate(); bookWnd.Show(); }