예제 #1
0
        private void BtnAddReprimand_Click(object sender, RoutedEventArgs e)
        {
            AddReprimand addReprimand = new AddReprimand();

            this.Opacity = 0.3;
            Filter();
            addReprimand.ShowDialog();
            Filter();
            this.Opacity = 1;
        }
예제 #2
0
 private void BtnEditReprimand_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         if (ListViewReprimands.SelectedItem is ViewReprimands reprimand)
         {
             VarIdReprimand = reprimand.IdPlaToRep;
             AddReprimand addReprimand = new AddReprimand(ListViewReprimands.SelectedItem as ViewReprimands);
             this.Opacity = 0.3;
             Filter();
             addReprimand.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);
     }
 }