Esempio n. 1
0
        private void butSelectFK_Click(object sender, EventArgs e)
        {
            switch ((EhrCriterion)comboReminderCriterion.SelectedIndex)
            {
            case EhrCriterion.Problem:
                FormDiseaseDefs formD = new FormDiseaseDefs();
                formD.IsSelectionMode = true;
                formD.ShowDialog();
                if (formD.DialogResult != DialogResult.OK)
                {
                    RuleCur.CriterionFK = -1;
                    return;
                }
                RuleCur.CriterionFK = formD.SelectedDiseaseDefNum;
                break;

            case EhrCriterion.Medication:
                FormMedications formM = new FormMedications();
                formM.IsSelectionMode = true;
                formM.ShowDialog();
                if (formM.DialogResult != DialogResult.OK)
                {
                    RuleCur.CriterionFK = -1;
                    return;
                }
                RuleCur.CriterionFK = formM.SelectedMedicationNum;
                break;

            case EhrCriterion.Allergy:
                FormAllergySetup formA = new FormAllergySetup();
                formA.IsSelectionMode = true;
                formA.ShowDialog();
                if (formA.DialogResult != DialogResult.OK)
                {
                    RuleCur.CriterionFK = -1;
                    return;
                }
                RuleCur.CriterionFK = formA.SelectedAllergyDefNum;
                break;

            case EhrCriterion.ICD9:
                FormIcd9s FormICD9Select = new FormIcd9s();
                FormICD9Select.IsSelectionMode = true;
                FormICD9Select.ShowDialog();
                if (FormICD9Select.DialogResult != DialogResult.OK)
                {
                    RuleCur.CriterionFK = -1;
                    return;
                }
                RuleCur.CriterionFK = FormICD9Select.SelectedIcd9Num;
                break;

            default:
                MessageBox.Show("You should never see this error message. Something has stopped working properly.");
                break;
            }
            FillFK();
        }
Esempio n. 2
0
        private void butAddAllergy_Click(object sender, EventArgs e)
        {
            FormAllergySetup FormAS = new FormAllergySetup();

            FormAS.IsSelectionMode = true;
            FormAS.ShowDialog();
            if (FormAS.DialogResult != DialogResult.OK)
            {
                return;
            }
            EhrTriggerCur.AllergyDefNumList += " " + FormAS.SelectedAllergyDefNum + " ";
            FillGrid();
        }
Esempio n. 3
0
 private void butAddAllergy_Click(object sender,EventArgs e)
 {
     FormAllergySetup FormAS=new FormAllergySetup();
     FormAS.IsSelectionMode=true;
     FormAS.ShowDialog();
     if(FormAS.DialogResult!=DialogResult.OK) {
         return;
     }
     RxAlert alert=new RxAlert();
     alert.AllergyDefNum=FormAS.SelectedAllergyDefNum;
     alert.RxDefNum=RxDefCur.RxDefNum;
     RxAlerts.Insert(alert);
     FillAlerts();
 }
Esempio n. 4
0
        private void butAddAllergy_Click(object sender, EventArgs e)
        {
            FormAllergySetup FormAS = new FormAllergySetup();

            FormAS.IsSelectionMode = true;
            FormAS.ShowDialog();
            if (FormAS.DialogResult != DialogResult.OK)
            {
                return;
            }
            RxAlert alert = new RxAlert();

            alert.AllergyDefNum = FormAS.SelectedAllergyDefNum;
            alert.RxDefNum      = RxDefCur.RxDefNum;
            RxAlerts.Insert(alert);
            FillAlerts();
        }
Esempio n. 5
0
        private void butAllergies_Click(object sender, EventArgs e)
        {
            FormAllergySetup FAS = new FormAllergySetup();

            FAS.ShowDialog();
        }
Esempio n. 6
0
		private void butSelectFK_Click(object sender,EventArgs e) {
			switch((EhrCriterion)comboReminderCriterion.SelectedIndex) {
				case EhrCriterion.Problem:
					FormDiseaseDefs formD=new FormDiseaseDefs();
					formD.IsSelectionMode=true;
					formD.ShowDialog();
					if(formD.DialogResult!=DialogResult.OK) {
						RuleCur.CriterionFK=-1;
						return;
					}
					RuleCur.CriterionFK=formD.SelectedDiseaseDefNum;
					break;
				case EhrCriterion.Medication:
					FormMedications formM=new FormMedications();
					formM.IsSelectionMode=true;
					formM.ShowDialog();
					if(formM.DialogResult!=DialogResult.OK) {
						RuleCur.CriterionFK=-1;
						return;
					}
					RuleCur.CriterionFK=formM.SelectedMedicationNum;
					break;
				case EhrCriterion.Allergy:
					FormAllergySetup formA=new FormAllergySetup();
					formA.IsSelectionMode=true;
					formA.ShowDialog();
					if(formA.DialogResult!=DialogResult.OK) {
						RuleCur.CriterionFK=-1;
						return;
					}
					RuleCur.CriterionFK=formA.SelectedAllergyDefNum;
					break;
				//case EhrCriterion.ICD9:
				//  FormIcd9s FormICD9Select = new FormIcd9s();
				//  FormICD9Select.IsSelectionMode=true;
				//  FormICD9Select.ShowDialog();
				//  if(FormICD9Select.DialogResult!=DialogResult.OK){
				//    RuleCur.CriterionFK=-1;
				//    return;
				//  }
				//  RuleCur.CriterionFK=ICD9s.GetByCode(FormICD9Select.SelectedIcd9Code).ICD9Num;
				//  break;
				default:
					MessageBox.Show("You should never see this error message. Something has stopped working properly.");
					break;
			}
			FillFK();
		}
		private void butPicker_Click(object sender,EventArgs e) {
			switch(listRestriction.SelectedIndex) {
				case 0://Birthdate
					//Not visible
					break;
				case 1://problem
					if(sender.Equals(butPicker)) {
						FormIcd9s FormI9=new FormIcd9s();
						FormI9.IsSelectionMode=true;
						FormI9.ShowDialog();
						if(FormI9.DialogResult!=DialogResult.OK) {
							return;
						}
						textCompareString.Text=FormI9.SelectedIcd9.ICD9Code;
						textSNOMED.Text="";
					}
					else if(sender.Equals(butSNOMED)) {
						FormSnomeds FormS=new FormSnomeds();
						FormS.IsSelectionMode=true;
						FormS.ShowDialog();
						if(FormS.DialogResult!=DialogResult.OK) {
							return;
						}
						textSNOMED.Text=FormS.SelectedSnomed.SnomedCode;
						textCompareString.Text="";
					}
					break;
				case 2://Medication
					FormMedications FormM=new FormMedications();
					FormM.IsSelectionMode=true;
					FormM.ShowDialog();
					if(FormM.DialogResult!=DialogResult.OK) {
						return;
					}
					textCompareString.Text=Medications.GetNameOnly(FormM.SelectedMedicationNum);
					break;
				case 3://LabResult
					FormLoincs FormL=new FormLoincs();
					FormL.IsSelectionMode=true;
					FormL.ShowDialog();
					if(FormL.DialogResult!=DialogResult.OK) {
						return;
					}
					textCompareString.Text=FormL.SelectedLoinc.LoincCode;
					comboUnits.Text=FormL.SelectedLoinc.UnitsUCUM;//may be valued, may be blank.
					break;
				case 4://Gender
					//Not visible
					break;
				case 5://Comm preference
					FormCommPrefPicker FormCPP = new FormCommPrefPicker();
					FormCPP.ShowDialog();
					if(FormCPP.DialogResult!=DialogResult.OK) {
						return;
					}
					textCompareString.Text=Enum.GetName(typeof(ContactMethod),FormCPP.ContMethCur);
					break;
				case 6://Alergy
					FormAllergySetup FormAS=new FormAllergySetup();
					FormAS.IsSelectionMode=true;
					FormAS.ShowDialog();
					if(FormAS.DialogResult!=DialogResult.OK) {
						return;
					}
					textCompareString.Text=AllergyDefs.GetDescription(FormAS.SelectedAllergyDefNum);
					break;
				default://should never happen
					break;
			}
		}
        private void butPicker_Click(object sender, EventArgs e)
        {
            switch (listRestriction.SelectedIndex)
            {
            case 0:                    //Birthdate
                //Not visible
                break;

            case 1:                    //problem
                if (sender.Equals(butPicker))
                {
                    FormIcd9s FormI9 = new FormIcd9s();
                    FormI9.IsSelectionMode = true;
                    FormI9.ShowDialog();
                    if (FormI9.DialogResult != DialogResult.OK)
                    {
                        return;
                    }
                    textCompareString.Text = FormI9.SelectedIcd9.ICD9Code;
                    textSNOMED.Text        = "";
                }
                else if (sender.Equals(butSNOMED))
                {
                    FormSnomeds FormS = new FormSnomeds();
                    FormS.IsSelectionMode = true;
                    FormS.ShowDialog();
                    if (FormS.DialogResult != DialogResult.OK)
                    {
                        return;
                    }
                    textSNOMED.Text        = FormS.SelectedSnomed.SnomedCode;
                    textCompareString.Text = "";
                }
                break;

            case 2:                    //Medication
                FormMedications FormM = new FormMedications();
                FormM.IsSelectionMode = true;
                FormM.ShowDialog();
                if (FormM.DialogResult != DialogResult.OK)
                {
                    return;
                }
                textCompareString.Text = Medications.GetNameOnly(FormM.SelectedMedicationNum);
                break;

            case 3:                    //LabResult
                //Not visible
                break;

            case 4:                    //Gender
                //Not visible
                break;

            case 5:                    //Comm preference
                FormCommPrefPicker FormCPP = new FormCommPrefPicker();
                FormCPP.ShowDialog();
                if (FormCPP.DialogResult != DialogResult.OK)
                {
                    return;
                }
                textCompareString.Text = Enum.GetName(typeof(ContactMethod), FormCPP.ContMethCur);
                break;

            case 6:                    //Alergy
                FormAllergySetup FormAS = new FormAllergySetup();
                FormAS.IsSelectionMode = true;
                FormAS.ShowDialog();
                if (FormAS.DialogResult != DialogResult.OK)
                {
                    return;
                }
                textCompareString.Text = AllergyDefs.GetDescription(FormAS.SelectedAllergyDefNum);
                break;

            default:                    //should never happen
                break;
            }
        }
Esempio n. 9
0
		private void butAllergiesIndicateNone_Click(object sender,EventArgs e) {
			FormAllergySetup formA=new FormAllergySetup();
			formA.IsSelectionMode=true;
			formA.ShowDialog();
			if(formA.DialogResult!=DialogResult.OK) {
				return;
			}
			if(Prefs.UpdateLong(PrefName.AllergiesIndicateNone,formA.SelectedAllergyDefNum)) {
				_changed=true;
			}
			textAllergiesIndicateNone.Text=AllergyDefs.GetOne(formA.SelectedAllergyDefNum).Description;
		}
Esempio n. 10
0
		private void butAddAllergy_Click(object sender,EventArgs e) {
			FormAllergySetup FormA=new FormAllergySetup();
			FormA.IsSelectionMode=true;
			FormA.ShowDialog();
			if(FormA.DialogResult!=DialogResult.OK) {
				return;
			}
			ListObjects.Add(AllergyDefs.GetOne(FormA.SelectedAllergyDefNum));
			fillKnowledgeRequestitems();
		}
Esempio n. 11
0
 private void butAllergies_Click(object sender,EventArgs e)
 {
     FormAllergySetup FAS=new FormAllergySetup();
     FAS.ShowDialog();
 }
Esempio n. 12
0
		private void butAddAllergy_Click(object sender,EventArgs e) {
			FormAllergySetup FormAS=new FormAllergySetup();
			FormAS.IsSelectionMode=true;
			FormAS.ShowDialog();
			if(FormAS.DialogResult!=DialogResult.OK) {
				return;
			}
			EhrTriggerCur.AllergyDefNumList+=" "+FormAS.SelectedAllergyDefNum+" ";
			FillGrid();
		}