public static void gridPat_CellDoubleClick(OpenDental.ContrFamily sender,Patient PatCur)
 {
     //again, named much like the original
     FormPatientEditP FormP=new FormPatientEditP();
     FormP.PatCur=PatCur;
     FormP.ShowDialog();
     sender.ModuleSelected(PatCur.PatNum);
 }
		private void gridVaccine_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e) {
			if(gridVaccine.GetSelectedIndex()==-1) {
				return;
			}
			FormEhrVaccinePatEdit FormV=new FormEhrVaccinePatEdit();
			FormV.VaccinePatCur=VaccineList[gridVaccine.GetSelectedIndex()];
			FormV.ShowDialog();
			FillGridVaccine();
		}
		private void gridMain_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e) {
			long vitalNum=listVs[e.Row].VitalsignNum;
			//change for EHR 2014
			FormVitalsignEdit2014 FormVSE=new FormVitalsignEdit2014();
			//FormEhrVitalsignEdit FormVSE=new FormEhrVitalsignEdit();
			FormVSE.VitalsignCur=Vitalsigns.GetOne(vitalNum);
			FormVSE.ShowDialog();
			FillGrid();
		}
 public static void InitializeOnStartup_end(OpenDental.ContrAccount sender)
 {
     contrAccountP=new ContrAccountP();
     sender.Controls.Add(contrAccountP.panelInsInfoDetail);
     //any control could be used here:
     Label label2=(Label)sender.Controls.Find("label2",true)[0];
     label2.MouseHover+=new EventHandler(contrAccountP.label2_MouseHover);
     label2.MouseLeave+=new EventHandler(contrAccountP.label2_MouseLeave);
 }
		private void gridMain_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e) {
			FormWikiListItemEdit FormWLIE = new FormWikiListItemEdit();
			FormWLIE.WikiListCurName=WikiListCurName;
			FormWLIE.ItemNum=PIn.Long(Table.Rows[e.Row][0].ToString());
			FormWLIE.ShowDialog();
			//saving occurs from within the form.
			if(FormWLIE.DialogResult!=DialogResult.OK) {
				return;
			}
			Table=WikiLists.GetByName(WikiListCurName);
			FillGrid();
		}
Exemple #6
0
		public static void InitializeOnStartup(ContrChart contrChart,TabControl tabProc,ODGrid gridProg,Panel panelEcw,
			TabControl tabControlImages,Size ClientSize,
			ODGrid gridPtInfo,ToothChartWrapper toothChart,RichTextBox textTreatmentNotes,OpenDental.UI.Button butECWup,
			OpenDental.UI.Button butECWdown,TabPage tabPatInfo)
		{
			tabProc.SelectedIndex=0;
			tabProc.Height=259;
			if(UsingEcwTightOrFull()) {
				toothChart.Location=new Point(524+2,26);
				textTreatmentNotes.Location=new Point(524+2,toothChart.Bottom+1);
				textTreatmentNotes.Size=new Size(411,40);//make it a bit smaller than usual
				gridPtInfo.Visible=false;
				panelEcw.Visible=true;
				panelEcw.Location=new Point(524+2,textTreatmentNotes.Bottom+1);
				panelEcw.Size=new Size(411,tabControlImages.Top-panelEcw.Top+1);
				butECWdown.Location=butECWup.Location;//they will be at the same location, but just hide one or the other.
				butECWdown.Visible=false;
				tabProc.Location=new Point(0,28);
				gridProg.Location=new Point(0,tabProc.Bottom+2);
				gridProg.Height=ClientSize.Height-gridProg.Location.Y-2;
			}
			else {//normal:
				toothChart.Location=new Point(0,26);
				textTreatmentNotes.Location=new Point(0,toothChart.Bottom+1);
				textTreatmentNotes.Size=new Size(411,71);
				gridPtInfo.Visible=true;
				gridPtInfo.Location=new Point(0,textTreatmentNotes.Bottom+1);
				panelEcw.Visible=false;
				tabProc.Location=new Point(415,28);
				gridProg.Location=new Point(415,tabProc.Bottom+2);
				gridProg.Height=ClientSize.Height-gridProg.Location.Y-2;
			}
			if(Programs.UsingOrion) {
				textTreatmentNotes.Visible=false;
				contrChart.Controls.Remove(gridPtInfo);
				gridPtInfo.Visible=true;
				gridPtInfo.Location=new Point(0,0);
				gridPtInfo.Size=new Size(tabPatInfo.ClientSize.Width,tabPatInfo.ClientSize.Height);
				gridPtInfo.Anchor=AnchorStyles.Left | AnchorStyles.Right | AnchorStyles.Top | AnchorStyles.Bottom;
				tabPatInfo.Controls.Add(gridPtInfo);
				tabProc.SelectedTab=tabPatInfo;
				tabProc.Height=toothChart.Height-1;
				gridProg.Location=new Point(0,toothChart.Bottom+2);
				gridProg.HScrollVisible=true;
				gridProg.Height=ClientSize.Height-gridProg.Location.Y-2;
				gridProg.Width=ClientSize.Width-gridProg.Location.X-1;//full width
			}
			else {
				tabProc.TabPages.Remove(tabPatInfo);
			}
		}
		private void gridMain_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e) {
			ConnectionGroup connGroup=_listCentralConnGroups[gridMain.SelectedIndices[0]].Copy();//Making copy so if they press cancel any changes won't persist.
			FormCentralConnectionGroupEdit FormCCGE=new FormCentralConnectionGroupEdit();
			FormCCGE.ConnectionGroupCur=connGroup;
			FormCCGE.ShowDialog();
			if(FormCCGE.DialogResult==DialogResult.OK) {
				if(FormCCGE.ConnectionGroupCur==null) {//Group was deleted in child window, remove it from list. (Deletion is also DialogResult.OK)
					_listCentralConnGroups.RemoveAt(gridMain.SelectedIndices[0]);
				}
				else{//Child window potentially updated the connection group, replace old version in list with current version.
					_listCentralConnGroups[gridMain.SelectedIndices[0]]=FormCCGE.ConnectionGroupCur;
				}
			}
			FillGrid();
		}
		private void gridMain_CellDoubleClick(object sender, OpenDental.UI.ODGridClickEventArgs e) {
			FormAutomationEdit FormA=new FormAutomationEdit(Automations.Listt[e.Row]);
			FormA.ShowDialog();
			FillGrid();
			changed=true;
		}
Exemple #9
0
 ///<summary>This is called when any local data becomes outdated.  It's purpose is to tell the other computers to update certain local data.</summary>
 private void DataValid_BecameInvalid(OpenDental.ValidEventArgs e)
 {
     if(e.OnlyLocal){
         if(!PrefsStartup()){//??
             return;
         }
         RefreshLocalData(InvalidType.AllLocal);//does local computer only
         return;
     }
     if(!e.ITypes.Contains((int)InvalidType.Date)
         && !e.ITypes.Contains((int)InvalidType.Task)
         && !e.ITypes.Contains((int)InvalidType.TaskPopup)){
         //local refresh for dates is handled within ContrAppt, not here
         InvalidType[] itypeArray=new InvalidType[e.ITypes.Count];
         for(int i=0;i<itypeArray.Length;i++){
             itypeArray[i]=(InvalidType)e.ITypes[i];
         }
         RefreshLocalData(itypeArray);//does local computer
     }
     string itypeString="";
     for(int i=0;i<e.ITypes.Count;i++){
         if(i>0){
             itypeString+=",";
         }
         itypeString+=e.ITypes[i].ToString();
     }
     Signalod sig=new Signalod();
     sig.ITypes=itypeString;
     if(e.ITypes.Contains((int)InvalidType.Date)){
         sig.DateViewing=e.DateViewing;
     }
     else{
         sig.DateViewing=DateTime.MinValue;
     }
     sig.SigType=SignalType.Invalid;
     if(e.ITypes.Contains((int)InvalidType.Task) || e.ITypes.Contains((int)InvalidType.TaskPopup)){
         sig.TaskNum=e.TaskNum;
     }
     Signalods.Insert(sig);
 }
Exemple #10
0
 private void lightSignalGrid1_ButtonClick(object sender,OpenDental.UI.ODLightSignalGridClickEventArgs e)
 {
     if(e.ActiveSignal!=null){//user trying to ack an existing light signal
         Signalods.AckButton(e.ButtonIndex+1,signalLastRefreshed);
         //then, manually ack the light on this computer.  The second ack in a few seconds will be ignored.
         lightSignalGrid1.SetButtonActive(e.ButtonIndex,Color.White,null);
         SigButDef butDef=SigButDefs.GetByIndex(e.ButtonIndex,SigButDefList);
         if(butDef!=null) {
             PaintOnIcon(butDef.SynchIcon,Color.White);
         }
         return;
     }
     if(e.ButtonDef==null || e.ButtonDef.ElementList.Length==0){//there is no signal to send
         return;
     }
     //user trying to send a signal
     Signalod sig=new Signalod();
     sig.SigType=SignalType.Button;
     //sig.ToUser=sigElementDefUser[listTo.SelectedIndex].SigText;
     //sig.FromUser=sigElementDefUser[listFrom.SelectedIndex].SigText;
     //need to do this all as a transaction?
     Signalods.Insert(sig);
     int row=0;
     Color color=Color.White;
     SigElementDef def;
     SigElement element;
     SigButDefElement[] butElements=SigButDefElements.GetForButton(e.ButtonDef.SigButDefNum);
     for(int i=0;i<butElements.Length;i++){
         element=new SigElement();
         element.SigElementDefNum=butElements[i].SigElementDefNum;
         element.SignalNum=sig.SignalNum;
         SigElements.Insert(element);
         if(SigElementDefs.GetElement(element.SigElementDefNum).SigElementType==SignalElementType.User){
             sig.ToUser=SigElementDefs.GetElement(element.SigElementDefNum).SigText;
             Signalods.Update(sig);
         }
         def=SigElementDefs.GetElement(element.SigElementDefNum);
         if(def.LightRow!=0) {
             row=def.LightRow;
         }
         if(def.LightColor.ToArgb()!=Color.White.ToArgb()) {
             color=def.LightColor;
         }
     }
     sig.ElementList=new SigElement[0];//we don't really care about these
     if(row!=0 && color!=Color.White) {
         lightSignalGrid1.SetButtonActive(row-1,color,sig);//this just makes it seem more responsive.
         //we can skip painting on the icon
     }
 }
Exemple #11
0
		private void gridMain_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e) {
			if(ViewRelat && listRelat.SelectedIndex==-1) {
				MessageBox.Show(Lan.g(this,"Please select a relationship first."));
				return;
			}
			if(ViewRelat) {
				PatRelat=(Relat)listRelat.SelectedIndex;
			}
			SelectedSub=SubList[e.Row];
			SelectedPlan=InsPlans.GetPlan(SubList[e.Row].PlanNum,PlanList);
			DialogResult=DialogResult.OK;
		}
		private void grid_CellDoubleClick(object sender, OpenDental.UI.ODGridClickEventArgs e) {
			SelectedPatNum=PIn.Long(Table.Rows[e.Row]["PatNum"].ToString());
			Cursor=Cursors.WaitCursor;
			long selectedApt=PIn.Long(Table.Rows[e.Row]["AptNum"].ToString());
			//Appointment apt=Appointments.GetOneApt(selectedApt);
			FormApptEdit FormA=new FormApptEdit(selectedApt);
			FormA.PinIsVisible=true;
			FormA.ShowDialog();
			if(FormA.PinClicked) {
				PinClicked=true;
				AptSelected=selectedApt;
				DialogResult=DialogResult.OK;
				return;
			}
			else {
				FillMain();
			}
			for(int i=0;i<Table.Rows.Count;i++){
				if(PIn.Long(Table.Rows[i]["AptNum"].ToString())==selectedApt){
					grid.SetSelected(i,true);
				}
			}
			SetFamilyColors();
			Cursor=Cursors.Default;
		}
Exemple #13
0
		private void ToolBarMain_ButtonClick(object sender,OpenDental.UI.ODToolBarButtonClickEventArgs e) {
			switch(e.Button.Tag.ToString()) {
				case "Add":
					Add_Click();
					break;
				case "Reconcile":
					Reconcile_Click();
					break;
				case "Print":
					Print_Click();
					break;
				case "Close":
					this.Close();
					break;
			}
		}
Exemple #14
0
		private void gridMain_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e) {
			RxSelected();
		}
Exemple #15
0
 private void gridMain_CellDoubleClick(object sender, OpenDental.UI.ODGridClickEventArgs e)
 {
     FormPayPeriodEdit FormP=new FormPayPeriodEdit(PayPeriods.List[e.Row]);
     FormP.ShowDialog();
     FillGrid();
     changed=true;
 }
		private void ToolBarMain_ButtonClick(object sender,OpenDental.UI.ODToolBarButtonClickEventArgs e) {
			if(e.Button.Tag.GetType()==typeof(string)) {
				switch(e.Button.Tag.ToString()) {
					case "Print":
						ToolBarPrint_Click();
						break;
					case "Delete":
						ToolBarDelete_Click();
						break;
					case "Info":
						ToolBarInfo_Click();
						break;
					case "Sign":
						ToolBarSign_Click();
						break;
					case "ScanDoc":
						ToolBarScan_Click("doc");
						break;
					case "ScanMultiDoc":
						ToolBarScanMulti_Click();
						break;
					case "ScanXRay":
						ToolBarScan_Click("xray");
						break;
					case "ScanPhoto":
						ToolBarScan_Click("photo");
						break;
					case "Import":
						ToolBarImport_Click();
						break;
					case "Export":
						ToolBarExport_Click();
						break;
					case "Copy":
						ToolBarCopy_Click();
						break;
					case "Paste":
						ToolBarPaste_Click();
						break;
					case "Forms":
						MsgBox.Show(this,"Use the dropdown list.  Add forms to the list by copying image files into your A-Z folder, Forms.  Restart the program to see newly added forms.");
						break;
					case "Capture":
						ToolBarCapture_Click();
						break;
					case "Close":
						ToolBarClose_Click();
						break;
				}
			}
			else if(e.Button.Tag.GetType()==typeof(long)) {
				ProgramL.Execute((long)e.Button.Tag,PatCur);
			}
		}
		private void grid_CellClick(object sender, OpenDental.UI.ODGridClickEventArgs e) {
			//row selected before this event triggered
			SelectedPatNum=PIn.Long(Table.Rows[e.Row]["PatNum"].ToString());
			SetFamilyColors();
			comboStatus.SelectedIndex=-1;
		}
		private void ToolBarMain_ButtonClick(object sender,OpenDental.UI.ODToolBarButtonClickEventArgs e) {
			switch(e.Button.Tag.ToString()) {
				case "Add":
					Add_Click();
					break;
				case "Edit":
					Edit_Click();
					break;
				case "Close":
					Close();
					break;
			}
			/*	case "Fwd":
					OnFwd_Click();
					break;
				
			}*/
		}
Exemple #19
0
 private void gridMain_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e)
 {
     bool isCat=false;
     long selectedKey=0;
     if(gridMain.Rows[e.Row].Tag.GetType()==typeof(CovCat)){
         isCat=true;
         selectedKey=((CovCat)gridMain.Rows[e.Row].Tag).CovCatNum;
         FormInsCatEdit FormE=new FormInsCatEdit((CovCat)gridMain.Rows[e.Row].Tag);
         FormE.ShowDialog();
         if(FormE.DialogResult!=DialogResult.OK) {
             return;
         }
     }
     else{//covSpan
         selectedKey=((CovSpan)gridMain.Rows[e.Row].Tag).CovSpanNum;
         FormInsSpanEdit FormE=new FormInsSpanEdit((CovSpan)gridMain.Rows[e.Row].Tag);
         FormE.ShowDialog();
         if(FormE.DialogResult!=DialogResult.OK){
             return;
         }
     }
     changed=true;
     FillSpans();
     for(int i=0;i<gridMain.Rows.Count;i++){
         if(isCat && gridMain.Rows[i].Tag.GetType()==typeof(CovCat)
             && selectedKey==((CovCat)gridMain.Rows[i].Tag).CovCatNum)
         {
             gridMain.SetSelected(i,true);
         }
         if(!isCat && gridMain.Rows[i].Tag.GetType()==typeof(CovSpan)
             && selectedKey==((CovSpan)gridMain.Rows[i].Tag).CovSpanNum)
         {
             gridMain.SetSelected(i,true);
         }
     }
 }
Exemple #20
0
		private void gridMain_CellDoubleClick(object sender, OpenDental.UI.ODGridClickEventArgs e) {
			FormApptRuleEdit FormA=new FormApptRuleEdit(AppointmentRuleC.List[e.Row]);
			FormA.ShowDialog();
			FillGrid();
			changed=true;
		}
Exemple #21
0
		private void gridEmp_CellClick(object sender, OpenDental.UI.ODGridClickEventArgs e) {
			if(PrefC.GetBool(PrefName.TimecardSecurityEnabled)){
				if(Security.CurUser.EmployeeNum!=_listEmployees[e.Row].EmployeeNum) {
					if(!Security.IsAuthorized(Permissions.TimecardsEditAll)){
						SelectEmpI(-1);
						return;
					}
				}
			}
			SelectEmpI(e.Row);
		}
Exemple #22
0
		private void gridLan_CellDoubleClick(object sender, OpenDental.UI.ODGridClickEventArgs e) {
			Language LanCur=LanList[e.Row];
			LanguageForeign lanForeign=LanguageForeigns.GetForCulture(ListForType,LanCur.English,CultureInfo.CurrentCulture.Name);
			LanguageForeign lanForeignOther=LanguageForeigns.GetOther(ListForType,LanCur.English,CultureInfo.CurrentCulture.Name);
			string otherTrans="";
			if(lanForeignOther!=null){
				otherTrans=lanForeignOther.Translation;
			}
			FormTranslationEdit FormTE=new FormTranslationEdit(LanCur,lanForeign,otherTrans);
			FormTE.ShowDialog();
			FillGrid();
		}
Exemple #23
0
 private void myOutlookBar_ButtonClicked(object sender, OpenDental.ButtonClicked_EventArgs e)
 {
     switch(myOutlookBar.SelectedIndex){
         case 0:
             if(!Security.IsAuthorized(Permissions.AppointmentsModule)){
                 e.Cancel=true;
                 return;
             }
             break;
         case 1:
             if(PrefC.GetBool(PrefName.EhrEmergencyNow)) {//if red emergency button is on
                 if(Security.IsAuthorized(Permissions.EhrEmergencyAccess,true)) {
                     break;//No need to check other permissions.
                 }
             }
             //Whether or not they were authorized by the special situation above,
             //they can get into the Family module with the ordinary permissions.
             if(!Security.IsAuthorized(Permissions.FamilyModule)) {
                 e.Cancel=true;
                 return;
             }
             break;
         case 2:
             if(!Security.IsAuthorized(Permissions.AccountModule)){
                 e.Cancel=true;
                 return;
             }
             break;
         case 3:
             if(!Security.IsAuthorized(Permissions.TPModule)){
                 e.Cancel=true;
                 return;
             }
             break;
         case 4:
             if(!Security.IsAuthorized(Permissions.ChartModule)){
                 e.Cancel=true;
                 return;
             }
             SecurityLogs.MakeLogEntry(Permissions.ChartModule,CurPatNum,"");
             break;
         case 5:
             if(!Security.IsAuthorized(Permissions.ImagesModule)){
                 e.Cancel=true;
                 return;
             }
             break;
         case 6:
             if(!Security.IsAuthorized(Permissions.ManageModule)){
                 e.Cancel=true;
                 return;
             }
             break;
     }
     UnselectActive();
     allNeutral();
     SetModuleSelected();
 }
		private void ToolBarMain_ButtonClick(object sender, OpenDental.UI.ODToolBarButtonClickEventArgs e) {
			//MessageBox.Show(e.Button.Tag.ToString());
			switch(e.Button.Tag.ToString()){
				case "Print":
					OnPrint_Click();
					break;
				case "Back":
					OnBack_Click();
					break;
				case "Fwd":
					OnFwd_Click();
					break;
				case "Close":
					OnClose_Click();
					break;
			}
		}
		///<summary></summary>
		protected static void OnBecameInvalid(OpenDental.ValidEventArgs e){
			if(BecameInvalid !=null){
				BecameInvalid(e);
			}
		}
Exemple #26
0
		private void ToolBarMain_ButtonClick(object sender,OpenDental.UI.ODToolBarButtonClickEventArgs e) {
			if(e.Button.Tag.GetType()==typeof(string)) {
				//standard predefined button
				switch(e.Button.Tag.ToString()) {
					case "Lists":
						OnLists_Click();
						break;
					case "Print":
						OnPrint_Click();
						break;
				}
			}
			else if(e.Button.Tag.GetType()==typeof(long)) {
				if(PatCur!=null) {
					Patient pat=Patients.GetPat(PatCur.PatNum);
					ProgramL.Execute((long)e.Button.Tag,pat);
				}
			}
		}
Exemple #27
0
 private void tbProvIdent_CellDoubleClicked(object sender, OpenDental.CellEventArgs e)
 {
     FormProviderIdentEdit FormP=new FormProviderIdentEdit();
     FormP.ProvIdentCur=ListProvIdent[e.Row];
     FormP.ShowDialog();
     FillProvIdent();
 }
Exemple #28
0
		private void ToolBarMain_ButtonClick(object sender,OpenDental.UI.ODToolBarButtonClickEventArgs e) {
			switch(e.Button.Tag.ToString()) {
				case "Save":
					Save_Click();
					break;
				case "Cancel":
					Cancel_Click();
					break;
				case "Int Link": 
					Int_Link_Click(); 
					break;
				case "File Link":
					File_Link_Click();
					break;
				case "Folder Link":
					Folder_Link_Click();
					break;
				case "Ext Link": 
					Ext_Link_Click(); 
					break;
				case "H1": 
					H1_Click(); 
					break;
				case "H2": 
					H2_Click(); 
					break;
				case "H3": 
					H3_Click(); 
					break;
				case "Table": 
					Table_Click();
					break;
				case "Image":
					Image_Click();
					break;
			}
		}
Exemple #29
0
 private void gridFees_CellDoubleClick(object sender,OpenDental.UI.ODGridClickEventArgs e)
 {
     Fee FeeCur=Fees.GetFee(ProcCode.CodeNum,FeeSchedC.ListShort[e.Row].FeeSchedNum);
     //tbFees.SelectedRow=e.Row;
     //tbFees.ColorRow(e.Row,Color.LightGray);
     FormFeeEdit FormFE=new FormFeeEdit();
     if(FeeCur==null) {
         FeeCur=new Fee();
         FeeCur.FeeSched=FeeSchedC.ListShort[e.Row].FeeSchedNum;
         FeeCur.CodeNum=ProcCode.CodeNum;
         Fees.Insert(FeeCur);
         FormFE.IsNew=true;
     }
     FormFE.FeeCur=FeeCur;
     FormFE.ShowDialog();
     if(FormFE.DialogResult==DialogResult.OK) {
         FeeChanged=true;
     }
     Fees.RefreshCache();
     //tbFees.SelectedRow=-1;
     FillFees();
 }
		private void ToolBarMain_ButtonClick(object sender, OpenDental.UI.ODToolBarButtonClickEventArgs e) {
			switch(e.Button.Tag.ToString()){
				case "Preview":
					toolBarButPreview_Click();
					break;
				case "Blank":
					toolBarButBlank_Click();
					break;
				case "Print":
					toolBarButPrint_Click();
					break;
				case "Labels":
					toolBarButLabels_Click();
					break;
				case "Eclaims":
					SendEclaimsToClearinghouse(0);
					break;
				case "Reports":
					toolBarButReports_Click();
					break;
				case "Outstanding":
					toolBarButOutstanding_Click();
					break;
				case "PayRec":
					toolBarButPayRec_Click();
					break;
				case "SummaryRec":
					toolBarButSummaryRec_Click();
					break;
				case "Close":
					Close();
					break;
			}
		}