private void pmInitPopUpDialog(string inDialogName) { switch (inDialogName.TrimEnd().ToUpper()) { case "CRZONE": if (this.pofrmGetCrZone == null) { this.pofrmGetCrZone = new DialogForms.dlgGetCrZone(); this.pofrmGetCrZone.Location = new Point(AppUtil.CommonHelper.SysMetric(1) - this.pofrmGetCrZone.Width - 10, AppUtil.CommonHelper.SysMetric(9) + 5); } break; case "TAG_PDGRP": using (DialogForms.dlgTagItems dlg = new mBudget.DialogForms.dlgTagItems()) { dlg.Location = new Point(AppUtil.CommonHelper.SysMetric(1) - dlg.Width - 10, AppUtil.CommonHelper.SysMetric(9) + 5); string strSQLExec = "select {0}.FCSKID, {0}.FCCODE, {0}.FCNAME from {0} "; string strFMDBName = App.ConfigurationManager.ConnectionInfo.ERPDBMSName; string strEmplRTab = strFMDBName + ".dbo.EMPLR"; strSQLExec = string.Format(strSQLExec, new string[] { MapTable.Table.ProdGroup, strEmplRTab }); dlg.SetBrowView(strSQLExec, null, MapTable.Table.ProdGroup, DialogForms.dlgGetPdGrp.MAXLENGTH_CODE, DialogForms.dlgGetPdGrp.MAXLENGTH_NAME); dlg.ShowDialog(); if (dlg.PopUpResult) { dlg.LoadTagValue(ref this.pATagCode); //this.txtTagCode.Text = this.pmGetRngCode(); } } break; } }
private void pmInitPopUpDialog(string inDialogName) { switch (inDialogName.TrimEnd().ToUpper()) { case "BRANCH": if (this.pofrmGetBranch == null) { this.pofrmGetBranch = new DialogForms.dlgGetBranch(); this.pofrmGetBranch.Location = new Point(AppUtil.CommonHelper.SysMetric(1) - this.pofrmGetBranch.Width - 10, AppUtil.CommonHelper.SysMetric(9) + 5); } break; case "BOOK": if (this.pofrmGetBook == null) { this.pofrmGetBook = new DialogForms.dlgGetBook(); this.pofrmGetBook.Location = new Point(AppUtil.CommonHelper.SysMetric(1) - this.pofrmGetBook.Width - 10, AppUtil.CommonHelper.SysMetric(9) + 5); } break; case "CRZONE": if (this.pofrmGetCrZone == null) { this.pofrmGetCrZone = new DialogForms.dlgGetCrZone(); this.pofrmGetCrZone.Location = new Point(AppUtil.CommonHelper.SysMetric(1) - this.pofrmGetCrZone.Width - 10, AppUtil.CommonHelper.SysMetric(9) + 5); } break; case "WKGRP": if (this.pofrmGetWkStat == null) { this.pofrmGetWkStat = new frmWorkStation(FormActiveMode.PopUp); //this.pofrmGetWkStat.Location = new Point(AppUtil.CommonHelper.SysMetric(1) - this.pofrmGetWkStat.Width - 10, AppUtil.CommonHelper.SysMetric(9) + 5); } break; } }