public frmQYDetail(string strF2, string strF8, string strF14) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); DataRow[] array = MDIParent.dsF.Tables["F"].Select(string.Concat(new string[] { "F2='", strF2, "'", (strF8 == "") ? "" : (" and F8='" + strF8 + "'"), (strF14 == "") ? "" : (" and F14='" + strF14 + "'") })); this.txtDWMC.Text = array[0]["F2"].ToString(); this.txtCountry.Text = array[0]["F3"].ToString(); this.txtProvince.Text = array[0]["F4"].ToString(); this.txtCity.Text = array[0]["F5"].ToString(); this.txtCounty.Text = array[0]["F6"].ToString(); this.txtAddress.Text = array[0]["F7"].ToString(); this.txtPostalcode.Text = array[0]["F11"].ToString(); this.txtPhone.Text = array[0]["F9"].ToString(); this.txtFax.Text = array[0]["F10"].ToString(); this.txtLXR.Text = array[0]["F14"].ToString(); this.txtEmail.Text = array[0]["F12"].ToString(); this.txtEmail.Text = array[0]["F13"].ToString(); this.txtDWLB.Text = array[0]["F8"].ToString(); }
public frmGroup(GridControl dv, string flag) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.dvgroup = (DataView)dv.DataSource; this.BindCombox(); this.comboBox1.SelectedIndex = 0; this.dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect; this.dataGridView1.ReadOnly = true; this.dataGridView1.AllowUserToAddRows = false; this.dataGridView1.AllowUserToDeleteRows = false; this.dataGridView1.AllowUserToResizeRows = false; this.dataGridView1.MultiSelect = false; this.dataGridView1.RowHeadersWidth = 55; this.dataGridView1.BackgroundColor = this.BackColor; this.dataGridView1.EnableHeadersVisualStyles = false; this.dataGridView1.AllowUserToResizeColumns = false; this.dataGridView2.SelectionMode = DataGridViewSelectionMode.FullRowSelect; this.dataGridView2.ReadOnly = true; this.dataGridView2.AllowUserToAddRows = false; this.dataGridView2.AllowUserToDeleteRows = false; this.dataGridView2.AllowUserToResizeRows = false; this.dataGridView2.MultiSelect = false; this.dataGridView2.RowHeadersWidth = 55; this.dataGridView2.BackgroundColor = this.BackColor; this.dataGridView2.EnableHeadersVisualStyles = false; }
public frmHao(string flag) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.strflag = flag; }
public frmSYDW() { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.userManu1.navBarItem17.Appearance.ForeColor = Color.FromArgb(177, 81, 28); }
public frmZD2JJ() { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.SetGridControl(); this.userManu1.navBarItem23.Appearance.ForeColor = Color.FromArgb(177, 81, 28); }
public frmNYLB2YXCF() { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.SetGridControl(); this.userManu1.navBarItem24.Appearance.ForeColor = Color.FromArgb(177, 81, 28); }
public frmFilter(GridColumnCollection dcl) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.filtertype = "OTHER"; this.tempdcl = dcl; base.Height -= 120; this.grpNY.Visible = false; }
public frmYXCFDetail(string strE2, string strE3) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); string filterExpression; if (strE3.Length <= 0) { filterExpression = "E2='" + strE2 + "'"; } else { filterExpression = string.Concat(new string[] { "E2='", strE2, "' and E3='", strE3, "'" }); } DataRow[] array = MDIParent.dsAED.Tables["AED"].Select(filterExpression); this.strE1 = array[0]["E1"].ToString(); this.strLHXZ = array[0]["E9"].ToString().Trim(); this.strDX = array[0]["E16"].ToString().Trim(); this.strDX = this.strDX + "|" + array[0]["E17"].ToString().Trim(); this.strDX = this.strDX + "|" + array[0]["E18"].ToString().Trim(); this.strDX = this.strDX + "|" + array[0]["E15"].ToString().Trim(); this.strDX = this.strDX + "|" + array[0]["E13"].ToString().Trim(); this.strDX = this.strDX + "|" + array[0]["E14"].ToString().Trim(); this.strDX = this.strDX + "|" + array[0]["E23"].ToString().Trim(); this.strDX = this.strDX + "|" + array[0]["E24"].ToString().Trim(); this.strZYTD = array[0]["E12"].ToString().Trim(); this.strHJ = array[0]["E25"].ToString().Trim(); this.strHJ = this.strHJ + "|" + array[0]["E26"].ToString().Trim(); this.strHJ = this.strHJ + "|" + array[0]["E27"].ToString().Trim(); this.strHJ = this.strHJ + "|" + array[0]["E28"].ToString().Trim(); this.strJXY = array[0]["E19"].ToString().Trim(); this.strJXY = this.strJXY + "|" + array[0]["E20"].ToString().Trim(); this.strJXY = this.strJXY + "|" + array[0]["E21"].ToString().Trim(); this.txtChTYMC.Text = array[0]["E2"].ToString(); this.txtChBM.Text = array[0]["E4"].ToString(); this.txtEnTYMC.Text = array[0]["E3"].ToString(); this.txtEnBM.Text = array[0]["E5"].ToString(); this.txtFZS.Text = array[0]["E6"].ToString(); this.txtCADJH.Text = array[0]["E8"].ToString(); this.txtZYFS.Text = array[0]["E11"].ToString(); this.txtHXMC.Text = array[0]["E7"].ToString(); this.txtFXFF.Text = array[0]["E10"].ToString(); this.txtNYLB.Text = array[0]["E29"].ToString(); this.txtHXFL.Text = array[0]["E30"].ToString(); this.txtZYSX.Text = array[0]["E18"].ToString(); }
public frmFilter(string FilterType) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.filtertype = FilterType; if (!(FilterType == "NY")) { base.Height -= 120; this.grpNY.Visible = false; } }
public frmSort(GridColumnCollection dcl) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.BindCombox1(dcl); this.BindCombox2(dcl); this.BindCombox3(dcl); this.BindCombox4(dcl); this.comboBox1.SelectedIndex = 0; this.comboBox2.SelectedIndex = 0; this.comboBox3.SelectedIndex = 0; this.comboBox4.SelectedIndex = 0; this.fillfinishok = true; }
public frmTJSYSPXX(string strZLBH) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); clsStr clsStr = new clsStr(); clsCommon clsCommon = new clsCommon(); this.initT14(); DataRow[] array = this.dsT14.Tables["t14"].Select("BH='" + strZLBH + "'"); this.lblQYMC.Text = array[0]["QYMC"].ToString() + ":"; this.strCPMC = array[0]["CPMC"].ToString(); this.strCPBM = array[0]["CPBM"].ToString(); DataTable dataTable = new DataTable(); dataTable.TableName = "Result"; dataTable.Columns.Add("ZW"); dataTable.Columns.Add("FZDX"); dataTable.Columns.Add("SPZT"); string[] array2 = clsStr.Seperate(array[0]["ZW"].ToString(), '|'); string[] array3 = clsStr.Seperate(array[0]["FZDX"].ToString(), '|'); string[] array4 = clsStr.Seperate(array[0]["SPZT"].ToString(), '|'); for (int i = 0; i < array2.Length; i++) { if (!(array2[i].ToString() == "") || !(array3[i].ToString() == "")) { DataRow dataRow = dataTable.NewRow(); dataRow["ZW"] = array2[i]; dataRow["FZDX"] = array3[i]; string text = array4[i]; if (text != null) { if (text == "1") { dataRow["SPZT"] = "同意"; } } dataTable.Rows.Add(dataRow); } } this.grvZWFZDXSPXX.DataSource = dataTable; }
public frmView(GridColumnCollection dcl) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); for (int i = 0; i < dcl.Count; i++) { if (dcl[i].Visible) { this.listBox2.Items.Add(dcl[i].Caption); } else { this.listBox1.Items.Add(dcl[i].Caption); } } this.listBox2.SelectedIndex = this.listBox2.Items.Count - 1; if (this.listBox1.Items.Count > 0) { this.listBox1.SelectedIndex = this.listBox1.Items.Count - 1; } }
public frmNY() { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.SetGridControl(); }
public frmNYList(string strLinkType, string strConditions) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); clsStr clsStr = new clsStr(); DataView dataView = new DataView(MDIParent.dsP.Tables["P"]); switch (strLinkType) { case "QY_Used": dataView.RowFilter = string.Concat(new string[] { "F2='", strConditions, "' and R5>'", clsStr.Format(DateTime.Now.Date.ToString(), '-'), "'" }); this.SetHeaders_QY(); for (int i = 0; i < dataView.Count; i++) { DataRow dataRow = this.tblResult.NewRow(); dataRow["R1"] = dataView[i]["R1"]; dataRow["R2"] = dataView[i]["R2"]; dataRow["HL"] = dataView[i]["HL"]; dataRow["R12"] = dataView[i]["R12"]; dataRow["R4"] = dataView[i]["R4"]; dataRow["R5"] = dataView[i]["R5"]; dataRow["F2"] = dataView[i]["F2"]; dataRow["R13"] = dataView[i]["R13"]; dataRow["R11"] = dataView[i]["R11"]; dataRow["C2"] = dataView[i]["C2"].ToString().Replace("|", "、"); dataRow["T2"] = dataView[i]["T2"].ToString().Replace("|", "、"); dataRow["R10"] = dataView[i]["R10"].ToString().Replace("|", "、"); this.tblResult.Rows.Add(dataRow); } this.tblResult.DefaultView.Sort = "R5 desc"; this.grv.DataSource = this.tblResult.DefaultView; this.SetStyle_QY(); break; case "QY_Unused": dataView.RowFilter = string.Concat(new string[] { "F2='", strConditions, "' and R5<'", clsStr.Format(DateTime.Now.Date.ToString(), '-'), "'" }); this.SetHeaders_QY(); for (int i = 0; i < dataView.Count; i++) { DataRow dataRow = this.tblResult.NewRow(); dataRow["R1"] = dataView[i]["R1"]; dataRow["R2"] = dataView[i]["R2"]; dataRow["HL"] = dataView[i]["HL"]; dataRow["R12"] = dataView[i]["R12"]; dataRow["R4"] = dataView[i]["R4"]; dataRow["R5"] = dataView[i]["R5"]; dataRow["F2"] = dataView[i]["F2"]; dataRow["R13"] = dataView[i]["R13"]; dataRow["R11"] = dataView[i]["R11"]; dataRow["C2"] = dataView[i]["C2"].ToString().Replace("|", "、"); dataRow["T2"] = dataView[i]["T2"].ToString().Replace("|", "、"); dataRow["R10"] = dataView[i]["R10"].ToString().Replace("|", "、"); this.tblResult.Rows.Add(dataRow); } this.tblResult.DefaultView.Sort = "R5 desc"; this.grv.DataSource = this.tblResult.DefaultView; this.SetStyle_QY(); break; case "YXCF": { string[] array = clsStr.Seperate(strConditions, '|'); dataView.RowFilter = string.Concat(new string[] { "E2 like '%", array[0], "%' and E3 like '%", array[1], "%'" }); this.SetHeaders_YXCF(); for (int i = 0; i < dataView.Count; i++) { string[] array2 = clsStr.Seperate(dataView[i]["E2"].ToString(), '、'); string[] array3 = clsStr.Seperate(dataView[i]["E3"].ToString(), '、'); for (int j = 0; j < array2.Length; j++) { if (array2[j] == array[0] && array3[j] == array[1]) { DataRow dataRow = this.tblResult.NewRow(); dataRow["R1"] = dataView[i]["R1"]; dataRow["R2"] = dataView[i]["R2"]; dataRow["HL"] = dataView[i]["HL"]; dataRow["R12"] = dataView[i]["R12"]; dataRow["R4"] = dataView[i]["R4"]; dataRow["R5"] = dataView[i]["R5"]; dataRow["F2"] = dataView[i]["F2"]; dataRow["R13"] = dataView[i]["R13"]; dataRow["R11"] = dataView[i]["R11"]; dataRow["C2"] = dataView[i]["C2"].ToString().Replace("|", "、"); dataRow["T2"] = dataView[i]["T2"].ToString().Replace("|", "、"); dataRow["R10"] = dataView[i]["R10"].ToString().Replace("|", "、"); this.tblResult.Rows.Add(dataRow); break; } } } this.tblResult.DefaultView.Sort = "R5 desc"; this.grv.DataSource = this.tblResult.DefaultView; this.SetStyle_YXCF(); break; } case "ZWFZDX": { string[] array = clsStr.Seperate(strConditions, '|'); dataView.RowFilter = string.Concat(new string[] { "C2 like '%", array[0], "%' and T2 like '%", array[1], "%'" }); this.SetHeaders_ZWFZDX(); for (int i = 0; i < dataView.Count; i++) { bool flag = false; string[] array4 = clsStr.Seperate(dataView[i]["C2"].ToString(), '|'); string[] array5 = clsStr.Seperate(dataView[i]["T2"].ToString(), '|'); for (int j = 0; j < array4.Length; j++) { if (array4[j] == array[0] && array5[j] == array[1]) { flag = true; DataRow dataRow = this.tblResult.NewRow(); dataRow["R1"] = dataView[i]["R1"]; dataRow["R2"] = dataView[i]["R2"]; dataRow["HL"] = dataView[i]["HL"]; dataRow["R12"] = dataView[i]["R12"]; dataRow["R80"] = dataView[i]["R80"]; dataRow["R90"] = dataView[i]["R90"]; dataRow["R4"] = dataView[i]["R4"]; dataRow["R5"] = dataView[i]["R5"]; dataRow["F2"] = dataView[i]["F2"]; dataRow["R13"] = dataView[i]["R13"]; dataRow["R11"] = dataView[i]["R11"]; dataRow["C2"] = dataView[i]["C2"].ToString().Replace("|", "、"); dataRow["T2"] = dataView[i]["T2"].ToString().Replace("|", "、"); dataRow["R10"] = dataView[i]["R10"].ToString().Replace("|", "、"); this.tblResult.Rows.Add(dataRow); } if (flag) { break; } } } this.tblResult.DefaultView.Sort = "R5 desc"; this.grv.DataSource = this.tblResult.DefaultView; this.SetStyle_ZWFXDX(); break; } case "YXCF2JX": { string[] array = clsStr.Seperate(strConditions, '|'); dataView.RowFilter = string.Concat(new string[] { "E2 like '%", array[0], "%' and E3 like '%", array[1], "%' ", (array[2] == "") ? "" : (" and R13='" + array[2] + "'"), " and ", array[3] }); this.SetHeaders_JX(); for (int i = 0; i < dataView.Count; i++) { DataRow dataRow = this.tblResult.NewRow(); dataRow["R1"] = dataView[i]["R1"]; dataRow["R2"] = dataView[i]["R2"]; dataRow["HL"] = dataView[i]["HL"]; dataRow["R12"] = dataView[i]["R12"]; dataRow["R80"] = dataView[i]["R80"]; dataRow["R90"] = dataView[i]["R90"]; dataRow["R4"] = dataView[i]["R4"]; dataRow["R5"] = dataView[i]["R5"]; dataRow["F2"] = dataView[i]["F2"]; dataRow["R13"] = dataView[i]["R13"]; dataRow["R11"] = dataView[i]["R11"]; dataRow["C2"] = dataView[i]["C2"].ToString().Replace("|", "、"); dataRow["T2"] = dataView[i]["T2"].ToString().Replace("|", "、"); dataRow["R10"] = dataView[i]["R10"].ToString().Replace("|", "、"); this.tblResult.Rows.Add(dataRow); } this.tblResult.DefaultView.Sort = "R5 desc"; this.grv.DataSource = this.tblResult.DefaultView; this.SetStyle_JX(); break; } case "YXCF2ZWFXDX": { string[] array = clsStr.Seperate(strConditions, '|'); dataView.RowFilter = string.Concat(new string[] { "C2 like '%", array[0], "%' and T2 like '%", array[1], "%' and ", array[2] }); this.SetHeaders_ZWFZDX(); for (int i = 0; i < dataView.Count; i++) { bool flag = false; string[] array4 = clsStr.Seperate(dataView[i]["C2"].ToString(), '|'); string[] array5 = clsStr.Seperate(dataView[i]["T2"].ToString(), '|'); for (int j = 0; j < array4.Length; j++) { if (array4[j] == array[0] && array5[j] == array[1]) { flag = true; DataRow dataRow = this.tblResult.NewRow(); dataRow["R1"] = dataView[i]["R1"]; dataRow["R2"] = dataView[i]["R2"]; dataRow["HL"] = dataView[i]["HL"]; dataRow["R12"] = dataView[i]["R12"]; dataRow["R80"] = dataView[i]["R80"]; dataRow["R90"] = dataView[i]["R90"]; dataRow["R4"] = dataView[i]["R4"]; dataRow["R5"] = dataView[i]["R5"]; dataRow["F2"] = dataView[i]["F2"]; dataRow["R13"] = dataView[i]["R13"]; dataRow["R11"] = dataView[i]["R11"]; dataRow["C2"] = dataView[i]["C2"].ToString().Replace("|", "、"); dataRow["T2"] = dataView[i]["T2"].ToString().Replace("|", "、"); dataRow["R10"] = dataView[i]["R10"].ToString().Replace("|", "、"); this.tblResult.Rows.Add(dataRow); } if (flag) { break; } } } this.tblResult.DefaultView.Sort = "R5 desc"; this.grv.DataSource = this.tblResult.DefaultView; this.SetStyle_ZWFXDX(); break; } case "QYCPTJ": { this.SetHeaders_QYCPTJ(); DataRow[] array6 = MDIParent.dsP.Tables["P"].Select("", "F2"); DataRow[] array7 = MDIParent.dsF.Tables["F"].Select("", "F2"); DataTable dataTable = new DataTable(); dataTable = this.tblResult.Clone(); int second = DateTime.Now.Second; string text = second.ToString(); int num; if (text.Length > 1) { num = (int)Convert.ToInt16(text.Substring(text.Length - 1)); } else { num = (int)Convert.ToInt16(text); } int k = 0; for (int i = 0; i < array7.Length; i++) { while (k < array6.Length) { if (!(array7[i]["F2"].ToString() == array6[k]["F2"].ToString())) { break; } DataRow dataRow = dataTable.NewRow(); dataRow["R1"] = array6[k]["R1"]; dataRow["R2"] = array6[k]["R2"]; dataRow["HL"] = array6[k]["HL"]; dataRow["R12"] = array6[k]["R12"]; dataRow["R80"] = array6[k]["R80"]; dataRow["R90"] = array6[k]["R90"]; dataRow["R4"] = array6[k]["R4"]; dataRow["R5"] = array6[k]["R5"]; dataRow["F2"] = array7[i]["F2"]; dataRow["F9"] = array7[i]["F9"]; dataRow["F14"] = array7[i]["F14"]; dataRow["R11"] = array6[k]["R11"]; dataRow["R13"] = array6[k]["R13"]; dataRow["F8"] = array7[i]["F8"]; int num2 = (int)Convert.ToInt16(dataRow["R1"].ToString().Trim().Substring(dataRow["R1"].ToString().Trim().Length - 1)); if (num2 < num) { dataRow["XH"] = num2 - num + 10; } else { dataRow["XH"] = num2 - num; } if (dataRow["JS"].ToString().Trim() != "") { dataTable.Rows.Add(dataRow); } k++; } if (k == array6.Length) { break; } } this.tblResult = dataTable.Copy(); this.tblResult.DefaultView.Sort = "R5 desc"; this.grv.DataSource = this.tblResult.DefaultView; this.SetStyle_QYCPTJ(); break; } } }
public frmNYDetail(string strR1, string strF8, string strF14) { this.InitializeComponent(); clsMe clsMe = new clsMe(); clsMe.setFormStyl(this); this.strF8 = strF8; this.strF14 = strF14; clsStr clsStr = new clsStr(); DataRow[] array = MDIParent.dsP.Tables["P"].Select("R1='" + strR1 + "'"); this.txtDJZH.Text = array[0]["R1"].ToString(); this.txtYXQSRQ.Text = array[0]["R4"].ToString(); this.txtYXJZRQ.Text = array[0]["R5"].ToString(); this.txtDJMC.Text = array[0]["R2"].ToString(); this.txtDX.Text = array[0]["R11"].ToString(); this.txtJX.Text = array[0]["R13"].ToString(); this.txtDWMC.Text = array[0]["F2"].ToString(); this.txtNYLB.Text = array[0]["R12"].ToString(); this.txtXKZH.Text = array[0]["R80"].ToString(); this.txtQYBZ.Text = array[0]["R90"].ToString(); DataTable dataTable = new DataTable(); dataTable.TableName = "Result1"; dataTable.Columns.Add("E2"); dataTable.Columns.Add("E3"); dataTable.Columns.Add("R7"); string[] array2 = clsStr.Seperate(array[0]["E2"].ToString(), '、'); string[] array3 = clsStr.Seperate(array[0]["E3"].ToString(), '、'); string[] array4 = clsStr.Seperate(array[0]["R7"].ToString(), '、'); for (int i = 0; i < array2.Length; i++) { DataRow dataRow = dataTable.NewRow(); dataRow["E2"] = array2[i]; dataRow["E3"] = array3[i]; dataRow["R7"] = array4[i]; dataTable.Rows.Add(dataRow); } this.grvYXCF.DataSource = dataTable; DataTable dataTable2 = new DataTable(); dataTable2.TableName = "Result2"; dataTable2.Columns.Add("C2"); dataTable2.Columns.Add("T2"); dataTable2.Columns.Add("R10"); dataTable2.Columns.Add("R14"); string[] array5 = clsStr.Seperate(array[0]["C2"].ToString(), '|'); string[] array6 = clsStr.Seperate(array[0]["T2"].ToString(), '|'); string[] array7 = clsStr.Seperate(array[0]["R10"].ToString(), '|'); string[] array8 = clsStr.Seperate(array[0]["R14"].ToString(), '|'); for (int i = 0; i < array5.Length; i++) { if (!(array5[i].ToString() == "") || !(array6[i].ToString() == "")) { DataRow dataRow = dataTable2.NewRow(); dataRow["C2"] = array5[i]; dataRow["T2"] = array6[i]; dataRow["R10"] = array7[i]; dataRow["R14"] = array8[i]; dataTable2.Rows.Add(dataRow); } } this.grvZWFZDX.DataSource = dataTable2; this.pages = ((DataTable)this.grvZWFZDX.DataSource).Rows.Count / (this.pagesize + 1); if (this.pages * (this.pagesize + 1) != ((DataTable)this.grvZWFZDX.DataSource).Rows.Count) { this.pages++; } }