private void BtnEditCharacteristics_Click(object sender, RoutedEventArgs e) { try { if (ListViewMF.SelectedItem is FootDev2.AppData.ViewMFCharacteristics mfchara) { VarIdCharacteristics = mfchara.IdPlToChar; VarIdChara = mfchara.IdCharacteristics; AddMfCharacteristics addmf = new AddMfCharacteristics(ListViewMF.SelectedItem as FootDev2.AppData.ViewMFCharacteristics); this.Opacity = 0.3; Filter(); addmf.ShowDialog(); Filter(); this.Opacity = 1; } else { MessageBox.Show("You did not select player", "Error", MessageBoxButton.OK, MessageBoxImage.Error); } } catch { MessageBox.Show("Error", "Error", MessageBoxButton.OK, MessageBoxImage.Error); } }
private void BtnAddCharacteristics_Click(object sender, RoutedEventArgs e) { AddMfCharacteristics addmf = new AddMfCharacteristics(); this.Opacity = 0.3; Filter(); addmf.ShowDialog(); Filter(); this.Opacity = 1; }