private void UnassignedPresentations_MouseDoubleClick(object sender, MouseButtonEventArgs e) { var presentation = (PresentationDTO)((ListBox)sender).SelectedItem; PresentationDetails newWindow = new PresentationDetails(presentation); newWindow.ShowDialog(); }
private void DetailsButton_Click(object sender, RoutedEventArgs e) { if (PresentationsList.SelectedIndex >= 0) { var presentation = (PresentationDTO)PresentationsList.SelectedItem; PresentationDetails newWindow = new PresentationDetails(presentation); newWindow.ShowDialog(); } else { MessageBox.Show("Select presentation first"); } }