Example #1
0
 private void butOK_Click(object sender, EventArgs e)
 {
     if (textOrthoMonthsTreat.errorProvider1.GetError(textOrthoMonthsTreat) != "")
     {
         MsgBox.Show(this, "Default months treatment must be between 0 and 255 months.");
         return;
     }
     if (PrefC.GetBool(PrefName.ShowFeaturePatientClone) != checkPatClone.Checked)
     {
         MsgBox.Show(this, "You will need to restart OpenDental for this change to take effect.");
     }
     if (Prefs.UpdateBool(PrefName.ShowFeaturePatientClone, checkPatClone.Checked)
         | Prefs.UpdateBool(PrefName.ApptModuleShowOrthoChartItem, checkApptModuleShowOrthoChartItem.Checked)
         | Prefs.UpdateBool(PrefName.OrthoEnabled, checkOrthoEnabled.Checked)
         | Prefs.UpdateBool(PrefName.OrthoCaseInfoInOrthoChart, checkOrthoFinancialInfoInChart.Checked)
         | Prefs.UpdateBool(PrefName.OrthoClaimMarkAsOrtho, checkOrthoClaimMarkAsOrtho.Checked)
         | Prefs.UpdateBool(PrefName.OrthoClaimUseDatePlacement, checkOrthoClaimUseDatePlacement.Checked)
         | Prefs.UpdateByte(PrefName.OrthoDefaultMonthsTreat, PIn.Byte(textOrthoMonthsTreat.Text))
         | Prefs.UpdateBool(PrefName.OrthoInsPayConsolidated, checkConsolidateInsPayment.Checked)
         | Prefs.UpdateLong(PrefName.OrthoAutoProcCodeNum, _orthoAutoProcCodeNum)
         | Prefs.UpdateString(PrefName.OrthoPlacementProcsList, string.Join(",", _listOrthoPlacementCodeNums))
         | Prefs.UpdateString(PrefName.OrthoBandingCodes, PIn.String(textBandingCodes.Text))
         | Prefs.UpdateString(PrefName.OrthoVisitCodes, PIn.String(textVisitCodes.Text))
         | Prefs.UpdateString(PrefName.OrthoDebondCodes, PIn.String(textDebondCodes.Text))
         )
     {
         _hasChanges = true;
     }
     DialogResult = DialogResult.OK;
 }