private void gridMain_CellDoubleClick(object sender, ODGridClickEventArgs e) { object objCur = gridMain.Rows[e.Row].Tag; //gridMain is filled with assessments, interventions, and/or medications if (objCur.GetType().Name == "EhrMeasureEvent") { //if assessment, we will allow them to change the DateTEvent, but not the status or more info box FormEhrMeasureEventEdit FormM = new FormEhrMeasureEventEdit(); FormM.MeasCur = (EhrMeasureEvent)objCur; FormM.ShowDialog(); } if (objCur.GetType().Name == "Intervention") { FormInterventionEdit FormI = new FormInterventionEdit(); FormI.InterventionCur = (Intervention)objCur; FormI.IsAllTypes = false; FormI.IsSelectionMode = false; FormI.ShowDialog(); } if (objCur.GetType().Name == "MedicationPat") { FormMedPat FormMP = new FormMedPat(); FormMP.MedicationPatCur = (MedicationPat)objCur; FormMP.IsNew = false; FormMP.ShowDialog(); } FillGrid(); }
private void butAdd_Click(object sender, EventArgs e) { FormInterventionEdit FormInt = new FormInterventionEdit(); FormInt.InterventionCur = new Intervention(); FormInt.InterventionCur.IsNew = true; FormInt.InterventionCur.PatNum = PatCur.PatNum; FormInt.InterventionCur.ProvNum = PatCur.PriProv; FormInt.InterventionCur.DateEntry = DateTime.Now; FormInt.IsAllTypes = true; FormInt.IsSelectionMode = true; FormInt.ShowDialog(); FillGrid(); }
private void gridMain_CellDoubleClick(object sender, ODGridClickEventArgs e) { object objCur = gridMain.Rows[e.Row].Tag; if (objCur.GetType().Name == "Intervention") //grid can contain MedicationPat or Intervention objects, launch appropriate window { FormInterventionEdit FormInt = new FormInterventionEdit(); FormInt.InterventionCur = (Intervention)objCur; FormInt.IsAllTypes = false; FormInt.IsSelectionMode = false; FormInt.ShowDialog(); } if (objCur.GetType().Name == "MedicationPat") { FormMedPat FormMP = new FormMedPat(); FormMP.MedicationPatCur = (MedicationPat)objCur; FormMP.IsNew = false; FormMP.ShowDialog(); } FillGrid(); }
private void gridInterventions_CellDoubleClick(object sender, ODGridClickEventArgs e) { Object objCur = gridInterventions.Rows[e.Row].Tag; //the intervention grid will be filled with Interventions and MedicationPats, load form accordingly if (objCur is Intervention) { FormInterventionEdit FormI = new FormInterventionEdit(); FormI.InterventionCur = (Intervention)objCur; FormI.IsAllTypes = false; FormI.IsSelectionMode = false; FormI.InterventionCur.IsNew = false; FormI.ShowDialog(); } else if (objCur is MedicationPat) { FormMedPat FormMP = new FormMedPat(); FormMP.MedicationPatCur = (MedicationPat)objCur; FormMP.IsNew = false; FormMP.ShowDialog(); } FillGridInterventions(); }
private void butIntervention_Click(object sender, EventArgs e) { if (comboSmokeStatus.SelectedIndex == 0) //None { MessageBox.Show("You must select a smoking status."); return; } FormInterventionEdit FormInt = new FormInterventionEdit(); FormInt.InterventionCur = new Intervention(); FormInt.InterventionCur.IsNew = true; FormInt.InterventionCur.PatNum = PatCur.PatNum; FormInt.InterventionCur.ProvNum = PatCur.PriProv; FormInt.InterventionCur.DateEntry = PIn.Date(textDateAssessed.Text); FormInt.InterventionCur.CodeSet = InterventionCodeSet.TobaccoCessation; FormInt.IsAllTypes = false; FormInt.IsSelectionMode = true; FormInt.ShowDialog(); if (FormInt.DialogResult == DialogResult.OK) { FillGrid(); } }
private void butAdd_Click(object sender,EventArgs e) { FormInterventionEdit FormInt=new FormInterventionEdit(); FormInt.InterventionCur=new Intervention(); FormInt.InterventionCur.IsNew=true; FormInt.InterventionCur.PatNum=PatCur.PatNum; FormInt.InterventionCur.ProvNum=PatCur.PriProv; FormInt.InterventionCur.DateEntry=DateTime.Now; FormInt.IsAllTypes=true; FormInt.IsSelectionMode=true; FormInt.ShowDialog(); FillGrid(); }
private void gridMain_CellDoubleClick(object sender,ODGridClickEventArgs e) { object objCur=gridMain.Rows[e.Row].Tag; if(objCur.GetType().Name=="Intervention") {//grid can contain MedicationPat or Intervention objects, launch appropriate window FormInterventionEdit FormInt=new FormInterventionEdit(); FormInt.InterventionCur=(Intervention)objCur; FormInt.IsAllTypes=false; FormInt.IsSelectionMode=false; FormInt.ShowDialog(); } if(objCur.GetType().Name=="MedicationPat") { FormMedPat FormMP=new FormMedPat(); FormMP.MedicationPatCur=(MedicationPat)objCur; FormMP.IsNew=false; FormMP.ShowDialog(); } FillGrid(); }
private void butIntervention_Click(object sender,EventArgs e) { if(comboSmokeStatus.SelectedIndex==0) {//None MessageBox.Show("You must select a smoking status."); return; } FormInterventionEdit FormInt=new FormInterventionEdit(); FormInt.InterventionCur=new Intervention(); FormInt.InterventionCur.IsNew=true; FormInt.InterventionCur.PatNum=PatCur.PatNum; FormInt.InterventionCur.ProvNum=PatCur.PriProv; FormInt.InterventionCur.DateEntry=PIn.Date(textDateAssessed.Text); FormInt.InterventionCur.CodeSet=InterventionCodeSet.TobaccoCessation; FormInt.IsAllTypes=false; FormInt.IsSelectionMode=true; FormInt.ShowDialog(); if(FormInt.DialogResult==DialogResult.OK) { FillGrid(); } }
private void gridMain_CellDoubleClick(object sender,ODGridClickEventArgs e) { object objCur=gridMain.Rows[e.Row].Tag; //gridMain is filled with assessments, interventions, and/or medications if(objCur.GetType().Name=="EhrMeasureEvent") { //if assessment, we will allow them to change the DateTEvent, but not the status or more info box FormEhrMeasureEventEdit FormM=new FormEhrMeasureEventEdit((EhrMeasureEvent)objCur); FormM.ShowDialog(); } if(objCur.GetType().Name=="Intervention") { FormInterventionEdit FormI=new FormInterventionEdit(); FormI.InterventionCur=(Intervention)objCur; FormI.IsAllTypes=false; FormI.IsSelectionMode=false; FormI.ShowDialog(); } if(objCur.GetType().Name=="MedicationPat") { FormMedPat FormMP=new FormMedPat(); FormMP.MedicationPatCur=(MedicationPat)objCur; FormMP.IsNew=false; FormMP.ShowDialog(); } FillGrid(); }
private void butAdd_Click(object sender,EventArgs e) { FormInterventionEdit FormInt=new FormInterventionEdit(); FormInt.InterventionCur=new Intervention(); FormInt.InterventionCur.IsNew=true; FormInt.InterventionCur.PatNum=patCur.PatNum; FormInt.InterventionCur.ProvNum=patCur.PriProv; FormInt.InterventionCur.DateEntry=PIn.Date(textDateTaken.Text); FormInt.InterventionCur.CodeSet=intervCodeSet; FormInt.IsAllTypes=false; FormInt.IsSelectionMode=true; FormInt.ShowDialog(); if(FormInt.DialogResult==DialogResult.OK) { bool child=ageBeforeJanFirst<17; FillGridInterventions(child); } }