private void clear2_Click(object sender, RoutedEventArgs e)
 {
     regexOverride = true;
     Application.Current.Dispatcher.Invoke(() => { Waist2Measurement.Clear(); });
     Waist2Measurement.Focus();
     regexOverride = false;
 }
 //Decalres a BT measurement
 private void checkBox_Unchecked(object sender, RoutedEventArgs e)
 {
     regexOverride     = true;
     manualMeasurement = false;
     Application.Current.Dispatcher.Invoke(() => { Waist1Measurement.Clear(); Waist2Measurement.Clear(); Waist3Measurement.Clear(); });
     MessageBox.Show("You are now entering measurements with Bluetooth.");
     //////
     RunCleanUp();
     Waist1Measurement.Focus();
     ////////
     regexOverride = false;
 }
 bool regexOverride     = false;//allows usage of text box clear operations to delte old results by not having regex applied to user input
 private void checkBox_Checked(object sender, RoutedEventArgs e)
 {
     regexOverride     = true;
     manualMeasurement = true;
     Application.Current.Dispatcher.Invoke(() => { Waist1Measurement.Clear(); Waist2Measurement.Clear(); Waist3Measurement.Clear(); });
     MessageBox.Show("You are now entering measurements manually.\n\n" +
                     "Please ensure measurements are of 1 decimal place format\n\n" +
                     "For example, 80 cm should be inout as 80.0\n" +
                     "140 cm should be input as 140.0");
     //////
     RunCleanUp();
     Waist1Measurement.Focus();
     ///////
     regexOverride = false;
 }