private void CommandNuevo_Click(object sender, RoutedEventArgs e) { if (listBox.SelectedValue == null) { return; } dynamic selecttrab = listBox.SelectedItem; WinModifyPrenom modify = new WinModifyPrenom(int.Parse(listBox.SelectedValue.ToString()), selecttrab.Nombre); modify.ShowDialog(); }
private void listBox_MouseDoubleClick(object sender, MouseButtonEventArgs e) { if (listBox.SelectedValue == null) { return; } dynamic selecttrab = listBox.SelectedItem; WinModifyPrenom modify = new WinModifyPrenom(int.Parse(listBox.SelectedValue.ToString()), selecttrab.Nombre); modify.ShowDialog(); }