private void Window_Loaded(object sender, RoutedEventArgs e)
 {
     _numericUpDownAverage1.Text    = Average1Value.ToString();
     _numericUpDownAverage2.Text    = Average2Value.ToString();
     _numericUpDownAverage3.Text    = Average3Value.ToString();
     _labelAverage1Color.Background = new SolidColorBrush(Color.FromArgb(Average1Color.A, Average1Color.R, Average1Color.G, Average1Color.B));
     _labelAverage2Color.Background = new SolidColorBrush(Color.FromArgb(Average2Color.A, Average2Color.R, Average2Color.G, Average2Color.B));
     _labelAverage3Color.Background = new SolidColorBrush(Color.FromArgb(Average3Color.A, Average3Color.R, Average3Color.G, Average3Color.B));
     _checkBoxAverage1.IsChecked    = Average1Visibility;
     _checkBoxAverage2.IsChecked    = Average2Visibility;
     _checkBoxAverage3.IsChecked    = Average3Visibility;
 }
 private void _numericUpDownAverage1_TextChanged(object sender, TextChangedEventArgs e)
 {
     try
     {
         Convert.ToInt32(_numericUpDownAverage1.Text);
         Average1Value = Convert.ToInt32(_numericUpDownAverage1.Text);
     }
     catch (Exception)
     {
         _numericUpDownAverage1.Text = Average1Value.ToString();
     }
 }