| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using CoreFS.CA06;
- using Core.Mes.Client.Comm.Server;
- using Core.Mes.Client.Comm.Control;
- using Infragistics.Win.UltraWinGrid;
- using System.Collections;
- using Core.Mes.Client.Comm.Tool;
- using Core.StlMes.Client.YdmPipeManage.Controls;
- namespace Core.StlMes.Client.YdmPipeManage
- {
- public partial class FrmVarietieProduct : FrmBase
- {
- string strStartTime = "2010-01-01 00:00:00";//开始时间
- string strEndTime = "";//结束时间
- DataTable ds1 = new DataTable();
- DataTable ds2 = new DataTable();
- DataTable ds3 = new DataTable();
- DataTable ds4 = new DataTable();
- private int InCoun = 0;
- public FrmVarietieProduct()
- {
- InitializeComponent();
- }
- private void FrmVarietie_Load(object sender, EventArgs e)
- {
- //doQuery();
- }
- protected override void OnLoad(EventArgs e)
- {
- base.OnLoad(e);
- PipeManageClass.SetUltraGridRowFilter(ref GridProducode, true);
- PipeManageClass.SetUltraGridRowFilter(ref GridKind, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid1, true);
- PipeManageClass.SetUltraGridRowFilter(ref GridSteel, true);
- PipeManageClass.SetUltraGridRowFilter(ref GridzbSteel, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid2, true);
- PipeManageClass.SetUltraGridRowFilter(ref GridSpec, true);
- PipeManageClass.SetUltraGridRowFilter(ref GridzbSpec, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid3, true);
- PipeManageClass.SetUltraGridRowFilter(ref GridModel, true);
- PipeManageClass.SetUltraGridRowFilter(ref GridzbModel, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid4, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid5, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid6, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid7, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid8, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid9, true);
- PipeManageClass.SetUltraGridRowFilter(ref ultraGrid10, true);
- }
- /// <summary>
- /// 重写基类方法
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="ToolbarKey"></param>
- public override void ToolBar_Click(object sender, string ToolbarKey)
- {
- switch (ToolbarKey)
- {
- case "Query":
- doQuery();
- break;
- case "Save":
- doAdd();
- break;
- case "Delete":
- doDelete();
- break;
- case "Refresh":
- doRefresh();
- break;
- case "Export":
- doExport();
- break;
- case "Close":
- this.Close();
- break;
- }
- }
- /// <summary>
- /// 导出
- /// </summary>
- private void doExport()
- {
- if (ultraTabControl1.SelectedTab.Key.Equals("0"))
- {
- if (InCoun == 1)
- {
- GridHelper.ulGridToExcel(GridProducode, "产销系统品名");
- }
- else if (InCoun == 2)
- {
- GridHelper.ulGridToExcel(ultraGrid1, "品名对应关系");
- }
- else if (InCoun == 3)
- {
- GridHelper.ulGridToExcel(GridKind, "质保系统品名");
- }
- else
- {
- MessageUtil.ShowTips("请激活要导出的GRID!");
- return;
- }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("1"))
- {
- if (InCoun == 1)
- {
- GridHelper.ulGridToExcel(GridSteel, "产销系统钢级");
- }
- else if (InCoun == 2)
- {
- GridHelper.ulGridToExcel(ultraGrid2, "钢级对应关系");
- }
- else if (InCoun == 3)
- {
- GridHelper.ulGridToExcel(GridzbSteel, "质保系统钢级");
- }
- else
- {
- MessageUtil.ShowTips("请激活要导出的GRID!");
- return;
- }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("2"))
- {
- if (InCoun == 1)
- {
- GridHelper.ulGridToExcel(GridSpec, "产销系统规格");
- }
- else if (InCoun == 2)
- {
- GridHelper.ulGridToExcel(ultraGrid3, "规格对应关系");
- }
- else if (InCoun == 3)
- {
- GridHelper.ulGridToExcel(GridzbSpec, "质保系统规格");
- }
- else
- {
- MessageUtil.ShowTips("请激活要导出的GRID!");
- return;
- }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("3"))
- {
- if (InCoun == 1)
- {
- GridHelper.ulGridToExcel(GridModel, "产销系统扣型");
- }
- else if (InCoun == 2)
- {
- GridHelper.ulGridToExcel(ultraGrid4, "扣型对应关系");
- }
- else if (InCoun == 3)
- {
- GridHelper.ulGridToExcel(GridzbModel, "质保系统扣型");
- }
- else
- {
- MessageUtil.ShowTips("请激活要导出的GRID!");
- return;
- }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("4"))
- {
- if (InCoun == 1)
- {
- GridHelper.ulGridToExcel(ultraGrid5, "产销系统产线");
- }
- else if (InCoun == 2)
- {
- GridHelper.ulGridToExcel(ultraGrid6, "产线对应关系");
- }
- else if (InCoun == 3)
- {
- GridHelper.ulGridToExcel(ultraGrid7, "质保系统产线");
- }
- else
- {
- MessageUtil.ShowTips("请激活要导出的GRID!");
- return;
- }
- }
- else
- {
- if (InCoun == 1)
- {
- GridHelper.ulGridToExcel(ultraGrid8, "产销系统钢种");
- }
- else if (InCoun == 2)
- {
- GridHelper.ulGridToExcel(ultraGrid9, "钢种对应关系");
- }
- else if (InCoun == 3)
- {
- GridHelper.ulGridToExcel(ultraGrid10, "质保系统钢种");
- }
- else
- {
- MessageUtil.ShowTips("请激活要导出的GRID!");
- return;
- }
- }
- }
- /// <summary>
- /// 查询
- /// </summary>
- private void doQuery()
- {
- if (ultraTabControl1.SelectedTab.Key.Equals("0"))
- {
- DataTable dt1 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getKind", null, this.ob);
- GridHelper.CopyDataToDatatable(ref dt1, ref dataTable1, true);
- GridHelper.RefreshAndAutoSize(GridProducode);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("1"))
- {
- DataTable dt1 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getSteel", null, this.ob);
- GridHelper.CopyDataToDatatable(ref dt1, ref dtCX_Steel, true);
- GridHelper.RefreshAndAutoSize(GridSteel);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("2"))
- {
- DataTable dt1 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getSpec", null, this.ob);
- GridHelper.CopyDataToDatatable(ref dt1, ref dtCX_Spec, true);
- GridHelper.RefreshAndAutoSize(GridSpec);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("3"))
- {
- DataTable dt1 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getModel", null, this.ob);
- GridHelper.CopyDataToDatatable(ref dt1, ref dtCX_Model, true);
- GridHelper.RefreshAndAutoSize(GridModel);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("4"))
- {
- DataTable dt1 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getFactory", null, this.ob);
- GridHelper.CopyDataToDatatable(ref dt1, ref dataTable4, true);
- GridHelper.RefreshAndAutoSize(this.ultraGrid5);
- }
- else
- {
- DataTable dt1 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getGrade", null, this.ob);
- GridHelper.CopyDataToDatatable(ref dt1, ref dataTable7, true);
- GridHelper.RefreshAndAutoSize(this.ultraGrid8);
- }
- doQueryZB();
- }
- /// <summary>
- /// 保存
- /// </summary>
- private void doAdd()
- {
- if (ultraTabControl1.SelectedTab.Key.Equals("0"))
- {
- #region 品名对应关系
- UltraGridRow row = GridProducode.ActiveRow;
- UltraGridRow row1 = GridKind.ActiveRow;
- int counm = 0;
- if (row==null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- if (row.IsFilterRow) { MessageUtil.ShowTips("请选择产销系统品名!"); return; }
- if (row1 == null)
- {
- MessageUtil.ShowTips("质保无数据,不能进行此操作!");
- return;
- }
- ArrayList list = new ArrayList();
- //string strwhere = "";
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in GridKind.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- ArrayList listSave = new ArrayList();
- //listSave.Add(row.Cells["PRODUCCODE"].Text.Trim());
- listSave.Add(uRow.Cells["kind"].Text);
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryKind1", new object[] { listSave }, this.ob);
- if (dt.Rows.Count > 0)
- {
- MessageUtil.ShowTips("您选择的该条质保系统品名" + "【" + uRow.Cells["kind"].Text + "】" + "对应关系已存在,请重新选择!");
- return;
- }
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["PRODUCCODE"].Text);
- pram.Add(row.Cells["PRODUCNAME"].Text);
- pram.Add(row.Cells["PRODUC_JX"].Text);
- pram.Add(row.Cells["PRODUC_ENG"].Text);
- pram.Add(uRow.Cells["kind"].Text);
- pram.Add(this.UserInfo.GetUserName());
- list.Add(pram);
- //strwhere += uRow.Cells["kind"].Text.Trim() + ",";
- }
- }
-
- //DataTable dt1 = PipeManageClass.RowFilterDataTable(ds1, strwhere);
- //GridHelper.CopyDataToDatatable(ref dt1, ref dataTable3, true);
- //GridHelper.RefreshAndAutoSize(GridKind);
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择质保系统品名!");
- return;
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.addProduct", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("保存成功!");
- doQueryProduct();
- }
- #endregion
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("1"))
- {
- #region 钢级对应关系
- UltraGridRow row = GridSteel.ActiveRow;
- UltraGridRow row1 = GridzbSteel.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- if (row.IsFilterRow) { MessageUtil.ShowTips("请选择产销系统钢级!"); return; }
- if (row1 == null)
- {
- MessageUtil.ShowTips("质保无数据,不能进行此操作!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in GridzbSteel.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- ArrayList listSave = new ArrayList();
- //listSave.Add(row.Cells["STEELCODE"].Text.Trim());
- listSave.Add(uRow.Cells["steellevel"].Text);
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQuerySteel1", new object[] { listSave }, this.ob);
- if (dt.Rows.Count > 0)
- {
- MessageUtil.ShowTips("您选择该条质保系统钢级" +"【"+ uRow.Cells["steellevel"].Text +"】"+ "对应关系已存在,请重新选择!");
- return;
- }
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["STEELCODE"].Text);
- pram.Add(row.Cells["STEELNAME"].Text);
- pram.Add(uRow.Cells["steellevel"].Text);
- pram.Add(this.UserInfo.GetUserName());
- list.Add(pram);
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择质保系统钢级!");
- return;
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.addSteel", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("保存成功!");
- doQueryProduct();
- }
- #endregion}
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("2"))
- {
- #region 规格对应关系
- UltraGridRow row = GridSpec.ActiveRow;
- UltraGridRow row1 = GridzbSpec.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- if (row.IsFilterRow) { MessageUtil.ShowTips("请选择产销系统规格!"); return; }
- if (row1 == null)
- {
- MessageUtil.ShowTips("质保无数据,不能进行此操作!");
- return;
- }
-
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in GridzbSpec.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- ArrayList listSave = new ArrayList();
- //listSave.Add(row.Cells["SPEC_CODE"].Text.Trim());
- listSave.Add(uRow.Cells["gg"].Text);
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQuerySpec1", new object[] { listSave }, this.ob);
- if (dt.Rows.Count > 0)
- {
- MessageUtil.ShowTips("您选择的该条质保系统规格" +"【"+ uRow.Cells["gg"].Text+"】" + "对应关系已存在,请重新选择!");
- return;
- }
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["SPEC_CODE"].Text);
- pram.Add(row.Cells["SPEC_NAME"].Text);
- pram.Add(uRow.Cells["gg"].Text);
- pram.Add(this.UserInfo.GetUserName());
- list.Add(pram);
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择质保系统规格!");
- return;
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.addSpec", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("保存成功!");
- doQueryProduct();
- }
- #endregion}
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("3"))
- {
- #region 扣型对应关系
- UltraGridRow row = GridModel.ActiveRow;
- UltraGridRow row1 = GridzbModel.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- if (row.IsFilterRow) { MessageUtil.ShowTips("请选择产销系统扣型!"); return; }
- if (row1 == null)
- {
- MessageUtil.ShowTips("质保无数据,不能进行此操作!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in GridzbModel.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- ArrayList listSave = new ArrayList();
- //listSave.Add(row.Cells["MODEL_CODE"].Text.Trim());
- listSave.Add(uRow.Cells["typeofThread"].Text);
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryModel1", new object[] { listSave }, this.ob);
- if (dt.Rows.Count > 0)
- {
- MessageUtil.ShowTips("您选择的该条质保系统扣型" + "【" + uRow.Cells["typeofThread"].Text + "】" + "对应关系已存在,请重新选择!");
- return;
- }
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["MODEL_CODE"].Text);
- pram.Add(row.Cells["MODEL_DESC"].Text);
- pram.Add(uRow.Cells["typeofThread"].Text);
- pram.Add(this.UserInfo.GetUserName());
- list.Add(pram);
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择质保系统扣型!");
- return;
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.addModel", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("保存成功!");
- doQueryProduct();
- }
- #endregion
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("4"))
- {
- #region 产线对应关系
- UltraGridRow row = this.ultraGrid5.ActiveRow;
- UltraGridRow row1 = ultraGrid7.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- if (row.IsFilterRow) { MessageUtil.ShowTips("请选择产销系统产线!"); return; }
- if (row1 == null)
- {
- MessageUtil.ShowTips("质保无数据,不能进行此操作!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid7.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- ArrayList listSave = new ArrayList();
- //listSave.Add(row.Cells["MODEL_CODE"].Text.Trim());
- listSave.Add(uRow.Cells["factory"].Text);
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryFactory1", new object[] { listSave }, this.ob);
- if (dt.Rows.Count > 0)
- {
- MessageUtil.ShowTips("您选择的该条质保系统产线" + "【" + uRow.Cells["factory"].Text + "】" + "对应关系已存在,请重新选择!");
- return;
- }
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["PLINE_CODE"].Text);
- pram.Add(row.Cells["PLINE_NAME"].Text);
- pram.Add(uRow.Cells["factory"].Text);
- pram.Add(this.UserInfo.GetUserName());
- list.Add(pram);
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择质保系统产线!");
- return;
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.addFactory", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("保存成功!");
- doQueryProduct();
- }
- #endregion
- }
- else
- {
- #region 钢种对应关系
- UltraGridRow row = this.ultraGrid8.ActiveRow;
- UltraGridRow row1 = ultraGrid10.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- if (row.IsFilterRow) { MessageUtil.ShowTips("请选择产销系统钢种!"); return; }
- if (row1 == null)
- {
- MessageUtil.ShowTips("质保无数据,不能进行此操作!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid10.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- ArrayList listSave = new ArrayList();
- //listSave.Add(row.Cells["MODEL_CODE"].Text.Trim());
- listSave.Add(uRow.Cells["steelgrade"].Text);
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryGrade1", new object[] { listSave }, this.ob);
- if (dt.Rows.Count > 0)
- {
- MessageUtil.ShowTips("您选择的该条质保系统钢种" + "【" + uRow.Cells["steelgrade"].Text.Trim() + "】" + "对应关系已存在,请重新选择!");
- return;
- }
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["GRADECODE"].Text);
- pram.Add(row.Cells["GRADENAME"].Text);
- pram.Add(uRow.Cells["steelgrade"].Text);
- pram.Add(this.UserInfo.GetUserName());
- list.Add(pram);
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择质保系统钢种!");
- return;
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.addGrade", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("保存成功!");
- doQueryProduct();
- }
- #endregion
- }
- }
-
- /// <summary>
- /// 删除
- /// </summary>
- private void doDelete()
- {
- if (ultraTabControl1.SelectedTab.Key.Equals("0"))
- {
- #region 品名对应关系
- UltraGridRow row = ultraGrid1.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid1.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择产销系统与质保系统品名对应关系!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid1.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["PRODUCCODE"].Text);
- pram.Add(uRow.Cells["ZB_PRODUCNAME"].Text);
- list.Add(pram);
- }
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.deleteProduct", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("删除成功!");
- doQueryProduct();
- }
- else
- {
- MessageUtil.ShowTips("删除失败!");
- }
- #endregion
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("1"))
- {
- #region 钢级对应关系
- UltraGridRow row = ultraGrid2.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid2.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择产销系统与质保系统钢级对应关系!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid2.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["STEELCODE"].Text);
- pram.Add(uRow.Cells["ZB_STEELNAME"].Text);
- list.Add(pram);
- }
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.deleteSteel", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("删除成功!");
- doQueryProduct();
- }
- else
- {
- MessageUtil.ShowTips("删除失败!");
- }
- #endregion}
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("2"))
- {
- #region 规格对应关系
- UltraGridRow row = ultraGrid3.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid3.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择产销系统与质保系统规格对应关系!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid3.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["SPEC_CODE"].Text);
- pram.Add(uRow.Cells["ZB_SPEC_NAME"].Text);
- list.Add(pram);
- }
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.deleteSpec", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("删除成功!");
- doQueryProduct();
- }
- else
- {
- MessageUtil.ShowTips("删除失败!");
- }
- #endregion
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("3"))
- {
- #region 扣型对应关系
- UltraGridRow row = ultraGrid4.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid4.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择产销系统与质保系统扣型对应关系!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid4.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["MODEL_CODE"].Text);
- pram.Add(uRow.Cells["ZB_MODEL_DESC"].Text);
- list.Add(pram);
- }
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.deleteModel", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("删除成功!");
- doQueryProduct();
- }
- else
- {
- MessageUtil.ShowTips("删除失败!");
- }
- #endregion
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("4"))
- {
- #region 产线对应关系
- UltraGridRow row = ultraGrid6.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid6.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择产销系统与质保系统产线对应关系!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid6.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["PLINE_CODE"].Text);
- pram.Add(uRow.Cells["ZB_PLINENAME"].Text);
- list.Add(pram);
- }
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.deleteFactory", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("删除成功!");
- doQueryProduct();
- }
- else
- {
- MessageUtil.ShowTips("删除失败!");
- }
- #endregion
- }
- else
- {
- #region 钢种对应关系
- UltraGridRow row = ultraGrid9.ActiveRow;
- int counm = 0;
- if (row == null)
- {
- MessageUtil.ShowTips("无数据,不能进行此操作!");
- return;
- }
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid9.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- counm += 1;
- }
- }
- if (counm == 0)
- {
- MessageUtil.ShowTips("请选择产销系统与质保系统钢种对应关系!");
- return;
- }
- ArrayList list = new ArrayList();
- foreach (Infragistics.Win.UltraWinGrid.UltraGridRow uRow in ultraGrid9.Rows)
- {
- if (Convert.ToBoolean(uRow.Cells["CHK"].Text) == true)
- {
- ArrayList pram = new ArrayList();
- pram.Add(row.Cells["GRADECODE"].Text);
- pram.Add(uRow.Cells["ZB_GRADENAME"].Text);
- list.Add(pram);
- }
- }
- int count = ServerHelper.SetData("com.steering.pss.ydm.pipemanage.FrmVarietie.deleteGrade", new Object[] { list }, this.ob);
- if (count > 0)
- {
- MessageUtil.ShowTips("删除成功!");
- doQueryProduct();
- }
- else
- {
- MessageUtil.ShowTips("删除失败!");
- }
- #endregion
- }
- }
- /// <summary>
- /// 刷新
- /// </summary>
- private void doRefresh()
- {
- doQueryZB();
- }
- /// <summary>
- /// 查询质保系统数据
- /// </summary>
- private void doQueryZB()
- {
- try
- {
- this.Cursor = Cursors.WaitCursor; //控制鼠标的样式为等待
- if (Constant.WaitingForm == null)
- {
- Constant.WaitingForm = new WaitingForm();
- }
- Constant.WaitingForm.ShowToUser = true;
- Constant.WaitingForm.Show();
- Constant.WaitingForm.Update();
- if (ultraTabControl1.SelectedTab.Key.Equals("0"))
- {
- DataTable dt3 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryKind", null, this.ob);
- string intt = "";
- if (dt3.Rows.Count > 0)
- {
- for (int i = 0; i < dt3.Rows.Count; i++)
- {
- intt += "'" + dt3.Rows[i]["ZB_PRODUCNAME"].ToString() + "'" + ",";
- }
- }
- if (intt != "")
- {
- intt = intt.Substring(1, intt.Length - 3);
- }
- else
- intt = "";
- DataTable dt2 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getZBKind", new object[] { strStartTime, intt }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt2, ref dataTable3, true);
- GridHelper.RefreshAndAutoSize(GridKind);
- ds1 = dt2.Copy();
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("1"))
- {
- DataTable dt3 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQuerySteel", null, this.ob);
- string intt = "";
- if (dt3.Rows.Count > 0)
- {
- for (int i = 0; i < dt3.Rows.Count; i++)
- {
- intt += "'" + dt3.Rows[i]["ZB_STEELNAME"].ToString() + "'" + ",";
- }
- }
- if (intt != "")
- {
- intt = intt.Substring(1, intt.Length - 3);
- }
- else
- intt = "";
- DataTable dt2 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getZBSteel", new object[] { strStartTime, intt }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt2, ref dtZB_Steel, true);
- GridHelper.RefreshAndAutoSize(GridzbSteel);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("2"))
- {
- DataTable dt3 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQuerySpec", null, this.ob);
- StringBuilder intt = new StringBuilder();
- ArrayList listData = new ArrayList();
- string ss = "";
- DataTable dt2 = null;
- if (dt3.Rows.Count > 0)
- {
- for (int i = 0; i < dt3.Rows.Count; i++)
- {
- intt.Append("'" + dt3.Rows[i]["ZB_SPEC_NAME"].ToString() + "'" + ",");
- }
- ss = intt.ToString();
- if (ss != "")
- {
- ss = ss.Substring(1, ss.Length - 3);
- }
- dt2 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getZBSpec", new object[] { strStartTime }, this.ob);
- }
- //string ss = intt.ToString();
- //if (ss != "
- //{
- // ss = ss.Substring(1, ss.Length - 3);
- //}
- //else
- // ss = "";
- //DataTable dt2 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getZBSpec", new object[] { strStartTime, ss }, this.ob);
- DataRow[] drs = dt2.Select("GG IN ('" + ss + "')");
- foreach (DataRow dr in drs)
- {
- dt2.Rows.Remove(dr);
- }
- GridHelper.CopyDataToDatatable(ref dt2, ref dtZB_Spec, true);
- GridHelper.RefreshAndAutoSize(GridzbSpec);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("3"))
- {
- DataTable dt3 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryModel", null, this.ob);
- string intt = "";
- if (dt3.Rows.Count > 0)
- {
- for (int i = 0; i < dt3.Rows.Count; i++)
- {
- intt += "'" + dt3.Rows[i]["ZB_MODEL_DESC"].ToString() + "'" + ",";
- }
- }
- if (intt != "")
- {
- intt = intt.Substring(1, intt.Length - 3);
- }
- else
- intt = "";
- DataTable dt2 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getZBModel", new object[] { strStartTime, intt }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt2, ref dtZB_Model, true);
- GridHelper.RefreshAndAutoSize(GridzbModel);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("4"))
- {
- DataTable dt4 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryFactory", null, this.ob);
- string intt = "";
- if (dt4.Rows.Count > 0)
- {
- for (int i = 0; i < dt4.Rows.Count; i++)
- {
- intt += "'" + dt4.Rows[i]["ZB_PLINENAME"].ToString() + "'" + ",";
- }
- }
- if (intt != "")
- {
- intt = intt.Substring(1, intt.Length - 3);
- }
- else
- intt = "";
- DataTable dt2 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getZBFactory", new object[] { strStartTime, intt }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt2, ref dataTable6, true);
- GridHelper.RefreshAndAutoSize(ultraGrid7);
- }
- else
- {
- DataTable dt5 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getQueryGrade", null, this.ob);
- string intt = "";
- if (dt5.Rows.Count > 0)
- {
- for (int i = 0; i < dt5.Rows.Count; i++)
- {
- intt += "'" + dt5.Rows[i]["ZB_GRADENAME"].ToString() + "'" + ",";
- }
- }
- if (intt != "")
- {
- intt = intt.Substring(1, intt.Length - 3);
- }
- else
- intt = "";
- DataTable dt2 = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.getZBGrade", new object[] { strStartTime, intt }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt2, ref dataTable9, true);
- GridHelper.RefreshAndAutoSize(ultraGrid10);
- }
- this.Cursor = Cursors.Default;
- Constant.WaitingForm.ShowToUser = false;
- Constant.WaitingForm.Close();
- Constant.WaitingForm = null;
- }
- catch (Exception e)
- {
- this.Cursor = Cursors.Default;
- Constant.WaitingForm.ShowToUser = false;
- Constant.WaitingForm.Close();
- Constant.WaitingForm = null;
- }
- }
- /// <summary>
- /// 产销品名对应质保品名关系
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void GridProducode_AfterRowActivate(object sender, EventArgs e)
- {
- doQueryProduct();
- }
- /// <summary>
- /// 产销钢级对应质保钢级关系
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void GridSteel_AfterRowActivate(object sender, EventArgs e)
- {
- doQueryProduct();
- }
- /// <summary>
- /// 产销规格对应质保规格关系
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void GridSpec_AfterRowActivate(object sender, EventArgs e)
- {
- doQueryProduct();
- }
- /// <summary>
- /// 产销扣型对应质保扣型关系
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void GridModel_AfterRowActivate(object sender, EventArgs e)
- {
- doQueryProduct();
- }
- /// <summary>
- /// 产销产线对应质保产线关系
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void ultraGrid5_AfterRowActivate(object sender, EventArgs e)
- {
- doQueryProduct();
- }
- /// <summary>
- /// 产销钢种对应质保钢种关系
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void ultraGrid8_AfterRowActivate(object sender, EventArgs e)
- {
- doQueryProduct();
- }
- /// <summary>
- /// 查询对应关系
- /// </summary>
- private void doQueryProduct()
- {
- if (ultraTabControl1.SelectedTab.Key.Equals("0"))
- {
- UltraGridRow row = GridProducode.ActiveRow;
- if (row == null) return;
- string strProduct = row.Cells["PRODUCCODE"].Text;
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.queryProduct", new object[] { strProduct }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt, ref dataTable2, true);
- GridHelper.RefreshAndAutoSize(ultraGrid1);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("1"))
- {
- UltraGridRow row = GridSteel.ActiveRow;
- if (row == null) return;
- string strSteel = row.Cells["STEELCODE"].Text;
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.querySteel", new object[] { strSteel }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt, ref dtSteel, true);
- GridHelper.RefreshAndAutoSize(ultraGrid2);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("2"))
- {
- UltraGridRow row = GridSpec.ActiveRow;
- if (row == null) return;
- string strSpec = row.Cells["SPEC_CODE"].Text;
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.querySpec", new object[] { strSpec }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt, ref dtSpec, true);
- GridHelper.RefreshAndAutoSize(ultraGrid3);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("3"))
- {
- UltraGridRow row = GridModel.ActiveRow;
- if (row == null) return;
- string strModel = row.Cells["MODEL_CODE"].Text;
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.queryModel", new object[] { strModel }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt, ref dtModel, true);
- GridHelper.RefreshAndAutoSize(ultraGrid4);
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("4"))
- {
- UltraGridRow row = this.ultraGrid5.ActiveRow;
- if (row == null) return;
- string strfactory = row.Cells["PLINE_CODE"].Text;
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.queryFactory", new object[] { strfactory }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt, ref dataTable5, true);
- GridHelper.RefreshAndAutoSize(ultraGrid6);
- }
- else
- {
- UltraGridRow row = this.ultraGrid8.ActiveRow;
- if (row == null) return;
- string strgrade = row.Cells["GRADECODE"].Text;
- DataTable dt = ServerHelper.GetData("com.steering.pss.ydm.pipemanage.FrmVarietie.queryGrade", new object[] { strgrade }, this.ob);
- GridHelper.CopyDataToDatatable(ref dt, ref dataTable8, true);
- GridHelper.RefreshAndAutoSize(ultraGrid9);
- }
- }
- /// <summary>
- /// 托选
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- private void GridALL_AfterSelectChange(object sender, AfterSelectChangeEventArgs e)
- {
- if (ultraTabControl1.SelectedTab.Key.Equals("0"))
- {
- try
- {
- ultraGrid1.UpdateData();
- GridKind.UpdateData();
- foreach (UltraGridRow r in ultraGrid1.Rows)
- {
- r.Cells["CHK"].Value = r.Selected;
- }
- foreach (UltraGridRow r1 in GridKind.Rows)
- {
- r1.Cells["CHK"].Value = r1.Selected;
- }
- }
- catch { }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("1"))
- {
- try
- {
- ultraGrid2.UpdateData();
- GridzbSteel.UpdateData();
- foreach (UltraGridRow r in ultraGrid2.Rows)
- {
- r.Cells["CHK"].Value = r.Selected;
- }
- foreach (UltraGridRow r1 in GridzbSteel.Rows)
- {
- r1.Cells["CHK"].Value = r1.Selected;
- }
- }
- catch { }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("2"))
- {
- try
- {
- ultraGrid3.UpdateData();
- GridzbSpec.UpdateData();
- foreach (UltraGridRow r in ultraGrid3.Rows)
- {
- r.Cells["CHK"].Value = r.Selected;
- }
- foreach (UltraGridRow r1 in GridzbSpec.Rows)
- {
- r1.Cells["CHK"].Value = r1.Selected;
- }
- }
- catch { }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("3"))
- {
- try
- {
- ultraGrid4.UpdateData();
- GridzbModel.UpdateData();
- foreach (UltraGridRow r in ultraGrid4.Rows)
- {
- r.Cells["CHK"].Value = r.Selected;
- }
- foreach (UltraGridRow r1 in GridzbModel.Rows)
- {
- r1.Cells["CHK"].Value = r1.Selected;
- }
- }
- catch { }
- }
- else if (ultraTabControl1.SelectedTab.Key.Equals("4"))
- {
- try
- {
- ultraGrid6.UpdateData();
- ultraGrid5.UpdateData();
- foreach (UltraGridRow r in ultraGrid6.Rows)
- {
- r.Cells["CHK"].Value = r.Selected;
- }
- foreach (UltraGridRow r1 in ultraGrid5.Rows)
- {
- r1.Cells["CHK"].Value = r1.Selected;
- }
- }
- catch { }
- }
- else
- {
- try
- {
- ultraGrid9.UpdateData();
- ultraGrid8.UpdateData();
- foreach (UltraGridRow r in ultraGrid9.Rows)
- {
- r.Cells["CHK"].Value = r.Selected;
- }
- foreach (UltraGridRow r1 in ultraGrid8.Rows)
- {
- r1.Cells["CHK"].Value = r1.Selected;
- }
- }
- catch { }
- }
- }
- private void GridP1_Click(object sender, EventArgs e)
- {
- InCoun = 1;
- }
- private void GridP2_Click(object sender, EventArgs e)
- {
- InCoun = 2;
- }
- private void GridP3_Click(object sender, EventArgs e)
- {
- InCoun = 3;
- }
-
- }
- }
|