QCM030722.cs 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Windows.Forms;
  9. using CoreFS.CA06;
  10. using System.Collections;
  11. using Infragistics.Win;
  12. using Infragistics.Win.UltraWinGrid;
  13. using Core.LZMes.Client.QCM.QCM03;
  14. using System.Diagnostics;
  15. using Infragistics.Win.UltraWinEditors;
  16. namespace Core.LZMes.Client.QCM
  17. {
  18. public partial class QCM030722 : FrmBase
  19. {
  20. private string judge_type = "";//用于区分1检测中心和2轧钢厂
  21. public QCM030722()
  22. {
  23. InitializeComponent();
  24. }
  25. public override void ToolBar_Click(object sender, string ToolbarKey)
  26. {
  27. switch (ToolbarKey)
  28. {
  29. case "Query":
  30. this.DoQuery();
  31. break;
  32. case "Exit":
  33. this.Close();
  34. break;
  35. case "Unlock":
  36. this.Judge();
  37. break;
  38. case "Export":
  39. this.DoExport();
  40. break;
  41. case "CancelFx":
  42. CancelFx();
  43. break;
  44. }
  45. }
  46. private void CancelFx()
  47. {
  48. UltraGridRow ugr = this.ultraGrid2.ActiveRow;
  49. if (ugr == null)
  50. {
  51. MessageBox.Show("请选择数据!");
  52. return;
  53. }
  54. string material_no = ugr.Cells["MATERIAL_NO"].Value.ToString();
  55. if (MessageBox.Show(this, "是否对" + material_no + "取消放行操作?", "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
  56. {
  57. return;
  58. }
  59. QCM030607 frm = new QCM030607();
  60. string remark = "";
  61. if (frm.ShowDialog() == DialogResult.OK)
  62. {
  63. remark = frm._memo;
  64. if (remark == "")
  65. {
  66. MessageBox.Show("请录入备注信息!");
  67. return;
  68. }
  69. string lock_type_code = ugr.Cells["LOCK_TYPE_CODE"].Value.ToString();
  70. string lock_seq = ugr.Cells["LOCK_SEQ"].Value.ToString();
  71. string username = this.UserInfo.GetUserName();
  72. CoreClientParam ccp = new CoreClientParam();
  73. ccp.ServerName = "QCM.QCM03.QCM0307.QcmRejudgeApplyServiceImpl";
  74. ccp.MethodName = "CancelFx";
  75. ccp.ServerParams = new object[] { material_no, lock_type_code, lock_seq, username, remark };
  76. this.ExecuteNonQuery(ccp, CoreInvokeType.Internal);
  77. if (ccp.ReturnCode == -1)
  78. {
  79. return;
  80. }
  81. MessageBox.Show("取消放行成功!");
  82. DoQuery();
  83. }
  84. }
  85. private void Judge()
  86. {
  87. if (this.ultraGrid9.Selected.Rows.Count == 0)
  88. this.ultraGrid9.ActiveRow.Selected = true;
  89. List<UltraGridRow> lists = new List<UltraGridRow>();
  90. if (comboBox1.Text.Trim().ToString() == "")
  91. {
  92. MessageBox.Show("请选择异常材处置放向!");
  93. return;
  94. }
  95. if (comboBox1.Text.Trim().ToString() == "放行")
  96. {
  97. if (MessageBox.Show(this, "是否放行处置?", "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
  98. {
  99. return;
  100. }
  101. }
  102. else if (comboBox1.Text.Trim().ToString() == "解除")
  103. {
  104. if (MessageBox.Show(this, "是否解除处置?", "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
  105. {
  106. return;
  107. }
  108. }
  109. foreach (UltraGridRow ugr in this.ultraGrid9.Rows)
  110. {
  111. if (ugr.Cells["CHECK"].Text.ToString() == "True")
  112. {
  113. ArrayList al = new ArrayList();
  114. if (comboBox1.Text.Trim().ToString() != "改判")
  115. {
  116. string material = ugr.Cells["MATERIAL_NO"].Value.ToString();
  117. string lock_seq = ugr.Cells["LOCK_SEQ"].Value.ToString();
  118. string lock_type_code = ugr.Cells["LOCK_TYPE_CODE"].Value.ToString();
  119. string prodline = ugr.Cells["PLINE_CODE"].Value.ToString();
  120. string unlock_type_code = "";
  121. if (lock_type_code == "C" || lock_type_code == "P")
  122. {
  123. if (comboBox1.Text.Trim().ToString() == "放行")
  124. {
  125. unlock_type_code = "0";
  126. }
  127. else if (comboBox1.Text.Trim().ToString() == "解除")
  128. {
  129. unlock_type_code = "9";
  130. }
  131. string unlock_memo = ultraComboEditor1.Text.Trim().ToString();
  132. string username = this.UserInfo.GetUserName();
  133. string lock_id = ugr.Cells["LOCK_ID"].Value.ToString();
  134. al.Add(material);
  135. al.Add(lock_seq);
  136. al.Add(lock_type_code);
  137. al.Add(unlock_type_code);
  138. al.Add(unlock_memo);
  139. al.Add(username);
  140. al.Add(lock_id);
  141. if (ultraCombo1.Text.ToString() == "")
  142. { al.Add(""); }
  143. else
  144. {
  145. al.Add(ultraCombo1.Value.ToString());
  146. }
  147. al.Add(prodline);
  148. al.Add(this.comboBox4.Text.ToString());
  149. CoreClientParam ccp = new CoreClientParam();
  150. ccp.ServerName = "QCM.QCM03.QCM0307.QcmRejudgeApplyServiceImpl";
  151. ccp.MethodName = "doInformationSure";
  152. ccp.ServerParams = new object[] { al };
  153. ccp = this.ExecuteNonQuery(ccp, CoreInvokeType.Internal);
  154. if (ccp.ReturnCode == -1)
  155. {
  156. return;
  157. }
  158. lists.Add(ugr);
  159. }
  160. else
  161. {
  162. if (comboBox1.Text.Trim().ToString() == "放行")
  163. {
  164. unlock_type_code = "0";
  165. }
  166. else if (comboBox1.Text.Trim().ToString() == "解除")
  167. {
  168. unlock_type_code = "9";
  169. }
  170. string unlock_memo = this.ultraComboEditor1.Text.Trim().ToString();
  171. string username = this.UserInfo.GetUserName();
  172. string lock_id = ugr.Cells["LOCK_ID"].Value.ToString();
  173. string sf_type = ugr.Cells["SF_TYPE"].Value.ToString();
  174. al.Add(material);
  175. al.Add(lock_seq);
  176. al.Add(lock_type_code);
  177. al.Add(unlock_type_code);
  178. al.Add(unlock_memo);
  179. al.Add(username);
  180. al.Add(lock_id);
  181. if (ultraCombo1.Text.ToString() == "")
  182. { al.Add(""); }
  183. else
  184. {
  185. al.Add(ultraCombo1.Value.ToString());
  186. }
  187. al.Add(sf_type);
  188. al.Add(this.comboBox4.Text.ToString());
  189. CoreClientParam ccp = new CoreClientParam();
  190. ccp.ServerName = "QCM.QCM03.QCM0307.QcmRejudgeApplyServiceImpl";
  191. ccp.MethodName = "doInformationSureH2";
  192. ccp.ServerParams = new object[] { al };
  193. ccp = this.ExecuteNonQuery(ccp, CoreInvokeType.Internal);
  194. if (ccp.ReturnCode == -1)
  195. {
  196. return;
  197. }
  198. lists.Add(ugr);
  199. }
  200. }
  201. }
  202. }
  203. for (int i = 0; i < lists.Count; i++)
  204. {
  205. lists[i].Delete(false);
  206. }
  207. MessageBox.Show("异常处置成功!");
  208. }
  209. private void DoQuery()
  210. {
  211. if (this.ultraTabControl1.Tabs[0].Selected) //待判信息
  212. {
  213. DoQueryMe();
  214. }
  215. if (this.ultraTabControl1.Tabs[1].Selected) //判定记录
  216. {
  217. DoQueryRe();
  218. }
  219. }
  220. private void DoQueryMe()
  221. {
  222. try
  223. {
  224. this.dataSet1.Clear();
  225. this.dataSet8.Clear();
  226. string ebatchno = "";
  227. string sbatchno = BatchNo.Text.Trim();
  228. if (BatchNo1.Text.ToString() == "")
  229. {
  230. ebatchno = this.BatchNo.Text.Trim();
  231. }
  232. else
  233. {
  234. ebatchno = BatchNo1.Text.Trim();
  235. }
  236. string orderno = this.OrderNo.Text.Trim();
  237. string psc = this.PscDesc.Text.Trim();
  238. string prodline = this.comboBox3.Text.ToString();
  239. string lock_type_desc = this.comboBox5.Text.ToString();
  240. string heat_no = textBox1.Text.ToString();
  241. CoreClientParam ccp = new CoreClientParam();
  242. ccp.ServerName = "QCM.QCM03.QCM0307.QcmRejudgeApplyServiceImpl";
  243. if (String.IsNullOrEmpty(judge_type))
  244. {
  245. ccp.MethodName = "getInformationH";
  246. ccp.ServerParams = new object[] { this.dateTimePicker1.Value.ToString("yyyyMMdd"), this.dateTimePicker2.Value.ToString("yyyyMMdd"), sbatchno, ebatchno, orderno, psc, "1", prodline,lock_type_desc,heat_no,"2" };
  247. }
  248. else
  249. {
  250. ccp.MethodName = "getInformation2H";
  251. ccp.ServerParams = new object[] { this.dateTimePicker1.Value.ToString("yyyyMMdd"), this.dateTimePicker2.Value.ToString("yyyyMMdd"), sbatchno, ebatchno, orderno, psc, "1", prodline, judge_type,lock_type_desc,heat_no,"2" };
  252. }
  253. ccp.SourceDataTable = this.dataSet1.Tables[0];
  254. this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
  255. ccp = new CoreClientParam();
  256. ccp.ServerName = "QCM.QCM03.QCM0305.QcmJudgeSurfaceServiceImpl";
  257. ccp.MethodName = "findFlawDataB";
  258. ccp.ServerParams = new object[] { prodline };
  259. ccp.SourceDataTable = this.dataSet8.Tables[0];
  260. this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
  261. this.ultraCombo1.DataSource = ccp.SourceDataTable;
  262. }
  263. catch (Exception ex)
  264. {
  265. System.Diagnostics.Debug.WriteLine(ex.ToString());
  266. MessageBox.Show("系统出错,请联系管理人员", "警告");
  267. }
  268. }
  269. private void DoQueryRe()
  270. {
  271. try
  272. {
  273. this.dataSet2.Clear();
  274. string ebatchno = "";
  275. string sbatchno = BatchNo.Text.Trim();
  276. if (BatchNo1.Text.ToString() == "")
  277. {
  278. ebatchno = this.BatchNo.Text.Trim();
  279. }
  280. else
  281. {
  282. ebatchno = BatchNo1.Text.Trim();
  283. }
  284. string orderno = this.OrderNo.Text.Trim();
  285. string psc = this.PscDesc.Text.Trim();
  286. string prodline = this.comboBox3.Text.ToString();
  287. string lock_type_desc = this.comboBox5.Text.ToString();
  288. string heat_no = textBox1.Text.ToString();
  289. CoreClientParam ccp = new CoreClientParam();
  290. ccp.ServerName = "QCM.QCM03.QCM0307.QcmRejudgeApplyServiceImpl";
  291. if (String.IsNullOrEmpty(judge_type))
  292. {
  293. ccp.MethodName = "getAbnormalRecordInfoH";
  294. ccp.ServerParams = new object[] { this.dateTimePicker1.Value.ToString("yyyyMMdd"), this.dateTimePicker2.Value.ToString("yyyyMMdd"), sbatchno, ebatchno, orderno, psc, "1", prodline,lock_type_desc,heat_no,"2" };
  295. }
  296. else
  297. {
  298. ccp.MethodName = "getAbnormalRecordInfo2H";
  299. ccp.ServerParams = new object[] { this.dateTimePicker1.Value.ToString("yyyyMMdd"), this.dateTimePicker2.Value.ToString("yyyyMMdd"), sbatchno, ebatchno, orderno, psc, "1", prodline, judge_type,lock_type_desc,heat_no,"2" };
  300. }
  301. ccp.SourceDataTable = this.dataSet2.Tables[0];
  302. this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
  303. foreach (UltraGridRow ugrs in this.ultraGrid2.Rows)
  304. {
  305. if (ugrs.Cells["UNLOCK_TYPE_DESC"].Text.ToString().Contains("复样"))
  306. {
  307. ugrs.Appearance.BackColor = Color.Pink;
  308. }
  309. }
  310. }
  311. catch (Exception ex)
  312. {
  313. System.Diagnostics.Debug.WriteLine(ex.ToString());
  314. MessageBox.Show("系统出错,请联系管理人员", "警告");
  315. }
  316. }
  317. private void panel4_Paint(object sender, PaintEventArgs e)
  318. {
  319. }
  320. private void panel2_Paint(object sender, PaintEventArgs e)
  321. {
  322. }
  323. private void DoQueryC()
  324. {
  325. try
  326. {
  327. UltraGridRow ugr = this.ultraGrid9.ActiveRow;
  328. if (ugr == null)
  329. return;
  330. this.dataSet4.Clear();
  331. string design_key = ugr.Cells["design_key"].Value.ToString();
  332. string smp_no = ugr.Cells["smp_no"].Value.ToString();
  333. CoreClientParam ccp = new CoreClientParam();
  334. ccp.ServerName = "QCM.QCM03.QCM0301.QcmJhyElementsServiceImpl";
  335. ccp.MethodName = "GetChemeInfo";
  336. ccp.ServerParams = new object[] { design_key, smp_no};
  337. ccp.SourceDataTable = this.dataSet4.Tables[0];
  338. this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
  339. }
  340. catch (Exception ex)
  341. {
  342. System.Diagnostics.Debug.WriteLine(ex.ToString());
  343. MessageBox.Show("系统出错,请联系管理人员", "警告");
  344. }
  345. }
  346. private void ultraGrid9_DoubleClickCell(object sender, DoubleClickCellEventArgs e)
  347. {
  348. UltraGridRow ugr = e.Cell.Row;
  349. string lock_id = ugr.Cells["LOCK_ID"].Value.ToString();
  350. if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "F")
  351. {
  352. QCM030705 dlg = new QCM030705();
  353. dlg.lock_id = lock_id;
  354. dlg.ob = this.ob;
  355. dlg.ShowDialog();
  356. }
  357. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "D")
  358. {
  359. QCM030704 dlg = new QCM030704();
  360. dlg.lock_id = lock_id;
  361. dlg.ob = this.ob;
  362. dlg.ShowDialog();
  363. }
  364. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "C")
  365. {
  366. QCM030701 dlg = new QCM030701();
  367. dlg.lock_id = lock_id;
  368. dlg.ob = this.ob;
  369. dlg.ShowDialog();
  370. }
  371. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "P")
  372. {
  373. QCM030702 dlg = new QCM030702();
  374. dlg.lock_id = lock_id;
  375. dlg.ob = this.ob;
  376. dlg.ShowDialog();
  377. }
  378. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "S")
  379. {
  380. QCM030703 dlg = new QCM030703();
  381. dlg.lock_id = lock_id;
  382. dlg.ob = this.ob;
  383. dlg.ShowDialog();
  384. }
  385. }
  386. public static bool SetUltraComboEditor(ref UltraComboEditor cbEdt, ref ValueList vlist, bool bNull)
  387. {
  388. if (cbEdt == null || vlist == null)
  389. return false;
  390. cbEdt.Items.Clear();
  391. if (bNull)
  392. cbEdt.Items.Add(null, "");
  393. for (int i = 0; i < vlist.ValueListItems.Count; i++)
  394. {
  395. try
  396. {
  397. cbEdt.Items.Add(vlist.ValueListItems[i].DataValue, vlist.ValueListItems[i].DisplayText);
  398. }
  399. catch { }
  400. }
  401. return true;
  402. }
  403. public static ValueList GeneralValuelist(ref DataTable table, string strKey, string strText)
  404. {
  405. if (table == null || !table.Columns.Contains(strKey) || !table.Columns.Contains(strText))
  406. return null;
  407. ArrayList alist = new ArrayList();
  408. ValueList vlist = new ValueList();
  409. for (int i = 0; i < table.Rows.Count; i++)
  410. {
  411. try
  412. {
  413. if (!alist.Contains(table.Rows[i][strKey]))
  414. {
  415. alist.Add(table.Rows[i][strKey]);
  416. vlist.ValueListItems.Add(table.Rows[i][strKey], Convert.ToString(table.Rows[i][strText]));
  417. }
  418. }
  419. catch { }
  420. }
  421. return vlist;
  422. }
  423. private void QCM030706_Load(object sender, EventArgs e)
  424. {
  425. this.comboBox3.SelectedIndex = 0;
  426. this.ultraGrid9.DisplayLayout.Override.FilterUIType = FilterUIType.HeaderIcons;
  427. this.ultraGrid2.DisplayLayout.Override.FilterUIType = FilterUIType.HeaderIcons;
  428. this.dateTimePicker1.Value = System.DateTime.Now.AddDays(-7);
  429. judge_type = String.IsNullOrEmpty(this.CustomInfo) ? "" : this.CustomInfo;
  430. CoreClientParam ccp = new CoreClientParam();
  431. ccp.ServerName = "QCM.QCM01.QCM0106.QueryDefect";
  432. ccp.MethodName = "QueryMemo";
  433. ccp.ServerParams = new object[] { "ZHB" };
  434. ccp = this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
  435. DataTable table2 = ccp.SourceDataTable;
  436. ValueList valueList2 = GeneralValuelist(ref table2, "MEMO_CODE", "MEMO");
  437. ClsControlPack.SetUltraComboEditor(ref ultraComboEditor1, ref valueList2, false);
  438. }
  439. private void ultraGrid2_DoubleClickCell(object sender, DoubleClickCellEventArgs e)
  440. {
  441. UltraGridRow ugr = e.Cell.Row;
  442. string lock_id = ugr.Cells["LOCK_ID"].Value.ToString();
  443. if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "F")
  444. {
  445. QCM030705 dlg = new QCM030705();
  446. dlg.lock_id = lock_id;
  447. dlg.ob = this.ob;
  448. dlg.ShowDialog();
  449. }
  450. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "D")
  451. {
  452. QCM030704 dlg = new QCM030704();
  453. dlg.lock_id = lock_id;
  454. dlg.ob = this.ob;
  455. dlg.ShowDialog();
  456. }
  457. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "C")
  458. {
  459. QCM030701 dlg = new QCM030701();
  460. dlg.lock_id = lock_id;
  461. dlg.ob = this.ob;
  462. dlg.ShowDialog();
  463. }
  464. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "P")
  465. {
  466. QCM030702 dlg = new QCM030702();
  467. dlg.lock_id = lock_id;
  468. dlg.ob = this.ob;
  469. dlg.ShowDialog();
  470. }
  471. else if (ugr.Cells["LOCK_TYPE_CODE"].Value.ToString() == "S")
  472. {
  473. QCM030703 dlg = new QCM030703();
  474. dlg.lock_id = lock_id;
  475. dlg.ob = this.ob;
  476. dlg.ShowDialog();
  477. }
  478. }
  479. private void ultraTabControl1_Click(object sender, EventArgs e)
  480. {
  481. if (this.ultraTabControl1.Tabs[1].Selected) //判定记录
  482. {
  483. this.label9.Text = "处置时间";
  484. }
  485. if (this.ultraTabControl1.Tabs[0].Selected) //判定记录
  486. {
  487. this.label9.Text = "封锁时间";
  488. }
  489. }
  490. private void DoExport()
  491. {
  492. if (this.ultraTabControl1.Tabs[0].Selected) //待判信息
  493. {
  494. try
  495. {
  496. if (this.ultraGrid9.Rows.Count == 0)
  497. {
  498. MessageBox.Show("没有可以导出的数据", "提示");
  499. return;
  500. }
  501. if (this.saveFileDialog1.ShowDialog(this) == DialogResult.OK)
  502. {
  503. string fName = this.saveFileDialog1.FileName;
  504. this.ultraGridExcelExporter1.Export(this.ultraGrid9, fName);
  505. Process.Start(fName);
  506. }
  507. }
  508. catch (Exception ex)
  509. {
  510. System.Diagnostics.Debug.WriteLine(ex.ToString());
  511. }
  512. }
  513. if (this.ultraTabControl1.Tabs[1].Selected) //判定记录
  514. {
  515. try
  516. {
  517. if (this.ultraGrid2.Rows.Count == 0)
  518. {
  519. MessageBox.Show("没有可以导出的数据", "提示");
  520. return;
  521. }
  522. if (this.saveFileDialog1.ShowDialog(this) == DialogResult.OK)
  523. {
  524. string fName = this.saveFileDialog1.FileName;
  525. this.ultraGridExcelExporter1.Export(this.ultraGrid2, fName);
  526. Process.Start(fName);
  527. }
  528. }
  529. catch (Exception ex)
  530. {
  531. System.Diagnostics.Debug.WriteLine(ex.ToString());
  532. }
  533. }
  534. }
  535. private void label11_Click(object sender, EventArgs e)
  536. {
  537. //获取勾选的批次
  538. ultraGrid9.UpdateData();
  539. DataRow[] rows = dataTable1.Copy().Select("CHECK = 'True'");
  540. if (this.ultraGrid9.Rows.Count == 0 || rows.Length == 0)
  541. {
  542. return;
  543. }
  544. DataRow[] rows2 = rows.CopyToDataTable().Select("BATCH_NO = '" + rows[0]["BATCH_NO"].ToString() + "'");
  545. if (rows2.Length != rows.Length)
  546. {
  547. MessageBox.Show("选择了多个批次信息!");
  548. return;
  549. }
  550. foreach (UltraGridRow ugr in this.ultraGrid9.Rows)
  551. {
  552. if (ugr.Cells["BATCH_NO"].Text.ToString() == rows[0]["BATCH_NO"].ToString())
  553. {
  554. ugr.Cells["CHECK"].Value = "True";
  555. }
  556. }
  557. }
  558. private void checkBox2_CheckedChanged(object sender, EventArgs e)
  559. {
  560. foreach (UltraGridRow ugr in this.ultraGrid9.Rows.Where(p => p.IsFilteredOut == false).ToList())
  561. {
  562. if (checkBox2.Checked)
  563. {
  564. ugr.Cells["CHECK"].Value = "True";
  565. }
  566. else
  567. {
  568. ugr.Cells["CHECK"].Value = "False";
  569. }
  570. }
  571. }
  572. }
  573. }