Browse Source

批结果判断修改,主要是通过和撤销通过的执行步骤

章政 8 years ago
parent
commit
0b45928af7

+ 130 - 171
UAS-MES/FunctionCode/OQC/OQC_BatchResultJudge.Designer.cs

@@ -47,6 +47,10 @@
             this.ob_maxngacceptqty_label = new System.Windows.Forms.Label();
             this.richTextBox1 = new System.Windows.Forms.RichTextBox();
             this.label5 = new System.Windows.Forms.Label();
+            this.ob_maxngacceptqty = new UAS_MES.CustomControl.TextBoxWithIcon.TextBoxNumOnly();
+            this.ob_source = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
+            this.ob_id = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
+            this.OperateResult = new UAS_MES.CustomControl.RichText.RichTextAutoBottom();
             this.GetBatch = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
             this.ob_prodcode = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
             this.ob_makecode = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
@@ -66,10 +70,6 @@
             this.WithdrawRejection = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
             this.BatchPass = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
             this.Clean = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
-            this.OperateResult = new UAS_MES.CustomControl.RichText.RichTextAutoBottom();
-            this.ob_id = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
-            this.ob_source = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
-            this.ob_maxngacceptqty = new UAS_MES.CustomControl.TextBoxWithIcon.TextBoxNumOnly();
             this.panel2.SuspendLayout();
             this.SuspendLayout();
             // 
@@ -77,10 +77,9 @@
             // 
             this.ob_batchqty_label.AutoSize = true;
             this.ob_batchqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_batchqty_label.Location = new System.Drawing.Point(680, 289);
-            this.ob_batchqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_batchqty_label.Location = new System.Drawing.Point(510, 231);
             this.ob_batchqty_label.Name = "ob_batchqty_label";
-            this.ob_batchqty_label.Size = new System.Drawing.Size(72, 27);
+            this.ob_batchqty_label.Size = new System.Drawing.Size(58, 21);
             this.ob_batchqty_label.TabIndex = 158;
             this.ob_batchqty_label.Text = "实批数";
             // 
@@ -88,10 +87,9 @@
             // 
             this.ob_result_label.AutoSize = true;
             this.ob_result_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_result_label.Location = new System.Drawing.Point(680, 238);
-            this.ob_result_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_result_label.Location = new System.Drawing.Point(510, 190);
             this.ob_result_label.Name = "ob_result_label";
-            this.ob_result_label.Size = new System.Drawing.Size(92, 27);
+            this.ob_result_label.Size = new System.Drawing.Size(74, 21);
             this.ob_result_label.TabIndex = 166;
             this.ob_result_label.Text = "判定结果";
             // 
@@ -99,10 +97,9 @@
             // 
             this.ob_okqty_label.AutoSize = true;
             this.ob_okqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_okqty_label.Location = new System.Drawing.Point(680, 395);
-            this.ob_okqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_okqty_label.Location = new System.Drawing.Point(510, 316);
             this.ob_okqty_label.Name = "ob_okqty_label";
-            this.ob_okqty_label.Size = new System.Drawing.Size(72, 27);
+            this.ob_okqty_label.Size = new System.Drawing.Size(58, 21);
             this.ob_okqty_label.TabIndex = 160;
             this.ob_okqty_label.Text = "合格数";
             // 
@@ -110,10 +107,9 @@
             // 
             this.ob_ngqty_label.AutoSize = true;
             this.ob_ngqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_ngqty_label.Location = new System.Drawing.Point(680, 448);
-            this.ob_ngqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_ngqty_label.Location = new System.Drawing.Point(510, 358);
             this.ob_ngqty_label.Name = "ob_ngqty_label";
-            this.ob_ngqty_label.Size = new System.Drawing.Size(92, 27);
+            this.ob_ngqty_label.Size = new System.Drawing.Size(74, 21);
             this.ob_ngqty_label.TabIndex = 162;
             this.ob_ngqty_label.Text = "不合格数";
             // 
@@ -121,10 +117,9 @@
             // 
             this.oi_checkqty_label.AutoSize = true;
             this.oi_checkqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.oi_checkqty_label.Location = new System.Drawing.Point(680, 342);
-            this.oi_checkqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.oi_checkqty_label.Location = new System.Drawing.Point(510, 274);
             this.oi_checkqty_label.Name = "oi_checkqty_label";
-            this.oi_checkqty_label.Size = new System.Drawing.Size(72, 27);
+            this.oi_checkqty_label.Size = new System.Drawing.Size(58, 21);
             this.oi_checkqty_label.TabIndex = 164;
             this.oi_checkqty_label.Text = "抽检数";
             // 
@@ -132,10 +127,9 @@
             // 
             this.ReworkRequire.AutoSize = true;
             this.ReworkRequire.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ReworkRequire.Location = new System.Drawing.Point(163, 656);
-            this.ReworkRequire.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ReworkRequire.Location = new System.Drawing.Point(122, 525);
             this.ReworkRequire.Name = "ReworkRequire";
-            this.ReworkRequire.Size = new System.Drawing.Size(154, 31);
+            this.ReworkRequire.Size = new System.Drawing.Size(125, 25);
             this.ReworkRequire.TabIndex = 168;
             this.ReworkRequire.Text = "发起返工需求";
             this.ReworkRequire.UseVisualStyleBackColor = true;
@@ -144,10 +138,9 @@
             // 
             this.ob_aqlcode_label.AutoSize = true;
             this.ob_aqlcode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_aqlcode_label.Location = new System.Drawing.Point(680, 502);
-            this.ob_aqlcode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_aqlcode_label.Location = new System.Drawing.Point(510, 402);
             this.ob_aqlcode_label.Name = "ob_aqlcode_label";
-            this.ob_aqlcode_label.Size = new System.Drawing.Size(52, 27);
+            this.ob_aqlcode_label.Size = new System.Drawing.Size(42, 21);
             this.ob_aqlcode_label.TabIndex = 169;
             this.ob_aqlcode_label.Text = "AQL";
             // 
@@ -155,10 +148,9 @@
             // 
             this.ob_prodcode_label.AutoSize = true;
             this.ob_prodcode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_prodcode_label.Location = new System.Drawing.Point(341, 178);
-            this.ob_prodcode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_prodcode_label.Location = new System.Drawing.Point(256, 142);
             this.ob_prodcode_label.Name = "ob_prodcode_label";
-            this.ob_prodcode_label.Size = new System.Drawing.Size(92, 27);
+            this.ob_prodcode_label.Size = new System.Drawing.Size(74, 21);
             this.ob_prodcode_label.TabIndex = 218;
             this.ob_prodcode_label.Text = "产品编号";
             // 
@@ -166,10 +158,9 @@
             // 
             this.ob_makecode_label.AutoSize = true;
             this.ob_makecode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_makecode_label.Location = new System.Drawing.Point(11, 179);
-            this.ob_makecode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_makecode_label.Location = new System.Drawing.Point(8, 143);
             this.ob_makecode_label.Name = "ob_makecode_label";
-            this.ob_makecode_label.Size = new System.Drawing.Size(72, 27);
+            this.ob_makecode_label.Size = new System.Drawing.Size(58, 21);
             this.ob_makecode_label.TabIndex = 216;
             this.ob_makecode_label.Text = "工单号";
             // 
@@ -177,10 +168,9 @@
             // 
             this.ob_checkno_label.AutoSize = true;
             this.ob_checkno_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_checkno_label.Location = new System.Drawing.Point(11, 51);
-            this.ob_checkno_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_checkno_label.Location = new System.Drawing.Point(8, 41);
             this.ob_checkno_label.Name = "ob_checkno_label";
-            this.ob_checkno_label.Size = new System.Drawing.Size(72, 27);
+            this.ob_checkno_label.Size = new System.Drawing.Size(58, 21);
             this.ob_checkno_label.TabIndex = 214;
             this.ob_checkno_label.Text = "抽检批";
             // 
@@ -188,10 +178,9 @@
             // 
             this.obd_outboxcode_label.AutoSize = true;
             this.obd_outboxcode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.obd_outboxcode_label.Location = new System.Drawing.Point(11, 91);
-            this.obd_outboxcode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.obd_outboxcode_label.Location = new System.Drawing.Point(8, 73);
             this.obd_outboxcode_label.Name = "obd_outboxcode_label";
-            this.obd_outboxcode_label.Size = new System.Drawing.Size(52, 27);
+            this.obd_outboxcode_label.Size = new System.Drawing.Size(42, 21);
             this.obd_outboxcode_label.TabIndex = 212;
             this.obd_outboxcode_label.Text = "箱号";
             // 
@@ -199,10 +188,9 @@
             // 
             this.ms_sncode_label.AutoSize = true;
             this.ms_sncode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ms_sncode_label.Location = new System.Drawing.Point(11, 134);
-            this.ms_sncode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ms_sncode_label.Location = new System.Drawing.Point(8, 107);
             this.ms_sncode_label.Name = "ms_sncode_label";
-            this.ms_sncode_label.Size = new System.Drawing.Size(72, 27);
+            this.ms_sncode_label.Size = new System.Drawing.Size(58, 21);
             this.ms_sncode_label.TabIndex = 210;
             this.ms_sncode_label.Text = "序列号";
             // 
@@ -213,9 +201,8 @@
             this.panel2.Controls.Add(this.label1);
             this.panel2.Dock = System.Windows.Forms.DockStyle.Top;
             this.panel2.Location = new System.Drawing.Point(0, 0);
-            this.panel2.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.panel2.Name = "panel2";
-            this.panel2.Size = new System.Drawing.Size(1309, 38);
+            this.panel2.Size = new System.Drawing.Size(982, 30);
             this.panel2.TabIndex = 220;
             this.panel2.Tag = "NoAuto";
             // 
@@ -224,10 +211,9 @@
             this.label1.AutoSize = true;
             this.label1.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.label1.ForeColor = System.Drawing.SystemColors.ActiveCaptionText;
-            this.label1.Location = new System.Drawing.Point(16, 5);
-            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label1.Location = new System.Drawing.Point(12, 4);
             this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(157, 27);
+            this.label1.Size = new System.Drawing.Size(127, 21);
             this.label1.TabIndex = 0;
             this.label1.Text = "OQC批结果判定";
             // 
@@ -235,10 +221,9 @@
             // 
             this.label3.AutoSize = true;
             this.label3.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label3.Location = new System.Drawing.Point(48, 568);
-            this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label3.Location = new System.Drawing.Point(36, 454);
             this.label3.Name = "label3";
-            this.label3.Size = new System.Drawing.Size(571, 24);
+            this.label3.Size = new System.Drawing.Size(444, 20);
             this.label3.TabIndex = 222;
             this.label3.Text = "--说明:如何物料没有维护AQL标准,需手动填写最大不合格允许通过数";
             // 
@@ -246,19 +231,17 @@
             // 
             this.ob_maxngacceptqty_label.AutoSize = true;
             this.ob_maxngacceptqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_maxngacceptqty_label.Location = new System.Drawing.Point(48, 532);
-            this.ob_maxngacceptqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_maxngacceptqty_label.Location = new System.Drawing.Point(36, 426);
             this.ob_maxngacceptqty_label.Name = "ob_maxngacceptqty_label";
-            this.ob_maxngacceptqty_label.Size = new System.Drawing.Size(212, 27);
+            this.ob_maxngacceptqty_label.Size = new System.Drawing.Size(170, 21);
             this.ob_maxngacceptqty_label.TabIndex = 223;
             this.ob_maxngacceptqty_label.Text = "最大不合格允许通过数";
             // 
             // richTextBox1
             // 
-            this.richTextBox1.Location = new System.Drawing.Point(117, 239);
-            this.richTextBox1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.richTextBox1.Location = new System.Drawing.Point(88, 191);
             this.richTextBox1.Name = "richTextBox1";
-            this.richTextBox1.Size = new System.Drawing.Size(547, 280);
+            this.richTextBox1.Size = new System.Drawing.Size(411, 225);
             this.richTextBox1.TabIndex = 225;
             this.richTextBox1.Text = "";
             // 
@@ -266,13 +249,63 @@
             // 
             this.label5.AutoSize = true;
             this.label5.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label5.Location = new System.Drawing.Point(11, 239);
-            this.label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label5.Location = new System.Drawing.Point(8, 191);
             this.label5.Name = "label5";
-            this.label5.Size = new System.Drawing.Size(52, 27);
+            this.label5.Size = new System.Drawing.Size(42, 21);
             this.label5.TabIndex = 226;
             this.label5.Text = "备注";
             // 
+            // ob_maxngacceptqty
+            // 
+            this.ob_maxngacceptqty.Location = new System.Drawing.Point(212, 426);
+            this.ob_maxngacceptqty.Name = "ob_maxngacceptqty";
+            this.ob_maxngacceptqty.Size = new System.Drawing.Size(194, 21);
+            this.ob_maxngacceptqty.TabIndex = 230;
+            this.ob_maxngacceptqty.Text = "0";
+            // 
+            // ob_source
+            // 
+            this.ob_source.AllPower = null;
+            this.ob_source.BackColor = System.Drawing.Color.White;
+            this.ob_source.Enabled = false;
+            this.ob_source.ID = null;
+            this.ob_source.Location = new System.Drawing.Point(759, 75);
+            this.ob_source.Name = "ob_source";
+            this.ob_source.Power = null;
+            this.ob_source.Size = new System.Drawing.Size(147, 21);
+            this.ob_source.Str = null;
+            this.ob_source.Str1 = null;
+            this.ob_source.Str2 = null;
+            this.ob_source.TabIndex = 229;
+            this.ob_source.Tag = "NoAuto";
+            this.ob_source.Visible = false;
+            // 
+            // ob_id
+            // 
+            this.ob_id.AllPower = null;
+            this.ob_id.BackColor = System.Drawing.Color.White;
+            this.ob_id.Enabled = false;
+            this.ob_id.ID = null;
+            this.ob_id.Location = new System.Drawing.Point(759, 55);
+            this.ob_id.Name = "ob_id";
+            this.ob_id.Power = null;
+            this.ob_id.Size = new System.Drawing.Size(147, 21);
+            this.ob_id.Str = null;
+            this.ob_id.Str1 = null;
+            this.ob_id.Str2 = null;
+            this.ob_id.TabIndex = 228;
+            this.ob_id.Tag = "NoAuto";
+            this.ob_id.Visible = false;
+            // 
+            // OperateResult
+            // 
+            this.OperateResult.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.OperateResult.Location = new System.Drawing.Point(760, 171);
+            this.OperateResult.Name = "OperateResult";
+            this.OperateResult.Size = new System.Drawing.Size(210, 319);
+            this.OperateResult.TabIndex = 227;
+            this.OperateResult.Text = "";
+            // 
             // GetBatch
             // 
             this.GetBatch.AllPower = "ifall";
@@ -280,13 +313,12 @@
             this.GetBatch.DownImage = ((System.Drawing.Image)(resources.GetObject("GetBatch.DownImage")));
             this.GetBatch.Image = ((System.Drawing.Image)(resources.GetObject("GetBatch.Image")));
             this.GetBatch.IsShowBorder = true;
-            this.GetBatch.Location = new System.Drawing.Point(681, 182);
-            this.GetBatch.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.GetBatch.Location = new System.Drawing.Point(511, 146);
             this.GetBatch.MoveImage = ((System.Drawing.Image)(resources.GetObject("GetBatch.MoveImage")));
             this.GetBatch.Name = "GetBatch";
             this.GetBatch.NormalImage = ((System.Drawing.Image)(resources.GetObject("GetBatch.NormalImage")));
             this.GetBatch.Power = "ifRead";
-            this.GetBatch.Size = new System.Drawing.Size(80, 30);
+            this.GetBatch.Size = new System.Drawing.Size(60, 24);
             this.GetBatch.TabIndex = 221;
             this.GetBatch.Text = "获取批";
             this.GetBatch.UseVisualStyleBackColor = true;
@@ -298,11 +330,10 @@
             this.ob_prodcode.BackColor = System.Drawing.Color.White;
             this.ob_prodcode.Enabled = false;
             this.ob_prodcode.ID = null;
-            this.ob_prodcode.Location = new System.Drawing.Point(473, 184);
-            this.ob_prodcode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_prodcode.Location = new System.Drawing.Point(355, 147);
             this.ob_prodcode.Name = "ob_prodcode";
             this.ob_prodcode.Power = null;
-            this.ob_prodcode.Size = new System.Drawing.Size(191, 25);
+            this.ob_prodcode.Size = new System.Drawing.Size(144, 21);
             this.ob_prodcode.Str = null;
             this.ob_prodcode.Str1 = null;
             this.ob_prodcode.Str2 = null;
@@ -315,11 +346,10 @@
             this.ob_makecode.BackColor = System.Drawing.Color.White;
             this.ob_makecode.Enabled = false;
             this.ob_makecode.ID = null;
-            this.ob_makecode.Location = new System.Drawing.Point(117, 181);
-            this.ob_makecode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_makecode.Location = new System.Drawing.Point(88, 145);
             this.ob_makecode.Name = "ob_makecode";
             this.ob_makecode.Power = null;
-            this.ob_makecode.Size = new System.Drawing.Size(212, 25);
+            this.ob_makecode.Size = new System.Drawing.Size(160, 21);
             this.ob_makecode.Str = null;
             this.ob_makecode.Str1 = null;
             this.ob_makecode.Str2 = null;
@@ -331,11 +361,10 @@
             this.ob_checkno.AllPower = "ifall";
             this.ob_checkno.BackColor = System.Drawing.Color.White;
             this.ob_checkno.ID = null;
-            this.ob_checkno.Location = new System.Drawing.Point(117, 54);
-            this.ob_checkno.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_checkno.Location = new System.Drawing.Point(88, 43);
             this.ob_checkno.Name = "ob_checkno";
             this.ob_checkno.Power = "ifread";
-            this.ob_checkno.Size = new System.Drawing.Size(547, 25);
+            this.ob_checkno.Size = new System.Drawing.Size(411, 21);
             this.ob_checkno.Str = null;
             this.ob_checkno.Str1 = null;
             this.ob_checkno.Str2 = null;
@@ -348,11 +377,10 @@
             this.obd_outboxcode.AllPower = null;
             this.obd_outboxcode.BackColor = System.Drawing.Color.White;
             this.obd_outboxcode.ID = null;
-            this.obd_outboxcode.Location = new System.Drawing.Point(117, 94);
-            this.obd_outboxcode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.obd_outboxcode.Location = new System.Drawing.Point(88, 75);
             this.obd_outboxcode.Name = "obd_outboxcode";
             this.obd_outboxcode.Power = null;
-            this.obd_outboxcode.Size = new System.Drawing.Size(547, 25);
+            this.obd_outboxcode.Size = new System.Drawing.Size(411, 21);
             this.obd_outboxcode.Str = null;
             this.obd_outboxcode.Str1 = null;
             this.obd_outboxcode.Str2 = null;
@@ -365,11 +393,10 @@
             this.ms_sncode.AllPower = "ifall";
             this.ms_sncode.BackColor = System.Drawing.Color.White;
             this.ms_sncode.ID = null;
-            this.ms_sncode.Location = new System.Drawing.Point(117, 136);
-            this.ms_sncode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ms_sncode.Location = new System.Drawing.Point(88, 109);
             this.ms_sncode.Name = "ms_sncode";
             this.ms_sncode.Power = "ifread";
-            this.ms_sncode.Size = new System.Drawing.Size(547, 25);
+            this.ms_sncode.Size = new System.Drawing.Size(411, 21);
             this.ms_sncode.Str = null;
             this.ms_sncode.Str1 = null;
             this.ms_sncode.Str2 = null;
@@ -383,11 +410,10 @@
             this.ob_batchqty.BackColor = System.Drawing.Color.White;
             this.ob_batchqty.Enabled = false;
             this.ob_batchqty.ID = null;
-            this.ob_batchqty.Location = new System.Drawing.Point(800, 289);
-            this.ob_batchqty.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_batchqty.Location = new System.Drawing.Point(600, 231);
             this.ob_batchqty.Name = "ob_batchqty";
             this.ob_batchqty.Power = null;
-            this.ob_batchqty.Size = new System.Drawing.Size(195, 25);
+            this.ob_batchqty.Size = new System.Drawing.Size(147, 21);
             this.ob_batchqty.Str = null;
             this.ob_batchqty.Str1 = null;
             this.ob_batchqty.Str2 = null;
@@ -400,11 +426,10 @@
             this.ob_okqty.BackColor = System.Drawing.Color.White;
             this.ob_okqty.Enabled = false;
             this.ob_okqty.ID = null;
-            this.ob_okqty.Location = new System.Drawing.Point(800, 395);
-            this.ob_okqty.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_okqty.Location = new System.Drawing.Point(600, 316);
             this.ob_okqty.Name = "ob_okqty";
             this.ob_okqty.Power = null;
-            this.ob_okqty.Size = new System.Drawing.Size(195, 25);
+            this.ob_okqty.Size = new System.Drawing.Size(147, 21);
             this.ob_okqty.Str = null;
             this.ob_okqty.Str1 = null;
             this.ob_okqty.Str2 = null;
@@ -417,11 +442,10 @@
             this.oi_checkqty.BackColor = System.Drawing.Color.White;
             this.oi_checkqty.Enabled = false;
             this.oi_checkqty.ID = null;
-            this.oi_checkqty.Location = new System.Drawing.Point(800, 342);
-            this.oi_checkqty.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.oi_checkqty.Location = new System.Drawing.Point(600, 274);
             this.oi_checkqty.Name = "oi_checkqty";
             this.oi_checkqty.Power = null;
-            this.oi_checkqty.Size = new System.Drawing.Size(195, 25);
+            this.oi_checkqty.Size = new System.Drawing.Size(147, 21);
             this.oi_checkqty.Str = null;
             this.oi_checkqty.Str1 = null;
             this.oi_checkqty.Str2 = null;
@@ -434,11 +458,10 @@
             this.ob_ngqty.BackColor = System.Drawing.Color.White;
             this.ob_ngqty.Enabled = false;
             this.ob_ngqty.ID = null;
-            this.ob_ngqty.Location = new System.Drawing.Point(800, 448);
-            this.ob_ngqty.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_ngqty.Location = new System.Drawing.Point(600, 358);
             this.ob_ngqty.Name = "ob_ngqty";
             this.ob_ngqty.Power = null;
-            this.ob_ngqty.Size = new System.Drawing.Size(195, 25);
+            this.ob_ngqty.Size = new System.Drawing.Size(147, 21);
             this.ob_ngqty.Str = null;
             this.ob_ngqty.Str1 = null;
             this.ob_ngqty.Str2 = null;
@@ -451,11 +474,10 @@
             this.ob_result.BackColor = System.Drawing.Color.White;
             this.ob_result.Enabled = false;
             this.ob_result.ID = null;
-            this.ob_result.Location = new System.Drawing.Point(800, 238);
-            this.ob_result.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_result.Location = new System.Drawing.Point(600, 190);
             this.ob_result.Name = "ob_result";
             this.ob_result.Power = null;
-            this.ob_result.Size = new System.Drawing.Size(195, 25);
+            this.ob_result.Size = new System.Drawing.Size(147, 21);
             this.ob_result.Str = null;
             this.ob_result.Str1 = null;
             this.ob_result.Str2 = null;
@@ -468,11 +490,10 @@
             this.ob_aqlcode.BackColor = System.Drawing.Color.White;
             this.ob_aqlcode.Enabled = false;
             this.ob_aqlcode.ID = null;
-            this.ob_aqlcode.Location = new System.Drawing.Point(800, 502);
-            this.ob_aqlcode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ob_aqlcode.Location = new System.Drawing.Point(600, 402);
             this.ob_aqlcode.Name = "ob_aqlcode";
             this.ob_aqlcode.Power = null;
-            this.ob_aqlcode.Size = new System.Drawing.Size(195, 25);
+            this.ob_aqlcode.Size = new System.Drawing.Size(147, 21);
             this.ob_aqlcode.Str = null;
             this.ob_aqlcode.Str1 = null;
             this.ob_aqlcode.Str2 = null;
@@ -487,13 +508,12 @@
             this.WithdrawPass.Enabled = false;
             this.WithdrawPass.Image = ((System.Drawing.Image)(resources.GetObject("WithdrawPass.Image")));
             this.WithdrawPass.IsShowBorder = true;
-            this.WithdrawPass.Location = new System.Drawing.Point(580, 606);
-            this.WithdrawPass.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.WithdrawPass.Location = new System.Drawing.Point(435, 485);
             this.WithdrawPass.MoveImage = ((System.Drawing.Image)(resources.GetObject("WithdrawPass.MoveImage")));
             this.WithdrawPass.Name = "WithdrawPass";
             this.WithdrawPass.NormalImage = ((System.Drawing.Image)(resources.GetObject("WithdrawPass.NormalImage")));
             this.WithdrawPass.Power = "ifWrite";
-            this.WithdrawPass.Size = new System.Drawing.Size(91, 38);
+            this.WithdrawPass.Size = new System.Drawing.Size(68, 30);
             this.WithdrawPass.TabIndex = 167;
             this.WithdrawPass.Text = "撤销通过";
             this.WithdrawPass.UseVisualStyleBackColor = true;
@@ -507,13 +527,12 @@
             this.BatchRejection.Enabled = false;
             this.BatchRejection.Image = ((System.Drawing.Image)(resources.GetObject("BatchRejection.Image")));
             this.BatchRejection.IsShowBorder = true;
-            this.BatchRejection.Location = new System.Drawing.Point(41, 658);
-            this.BatchRejection.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.BatchRejection.Location = new System.Drawing.Point(31, 526);
             this.BatchRejection.MoveImage = ((System.Drawing.Image)(resources.GetObject("BatchRejection.MoveImage")));
             this.BatchRejection.Name = "BatchRejection";
             this.BatchRejection.NormalImage = ((System.Drawing.Image)(resources.GetObject("BatchRejection.NormalImage")));
             this.BatchRejection.Power = "ifWrite";
-            this.BatchRejection.Size = new System.Drawing.Size(91, 38);
+            this.BatchRejection.Size = new System.Drawing.Size(68, 30);
             this.BatchRejection.TabIndex = 166;
             this.BatchRejection.Text = "批次退";
             this.BatchRejection.UseVisualStyleBackColor = true;
@@ -527,13 +546,12 @@
             this.ForcePass.Enabled = false;
             this.ForcePass.Image = ((System.Drawing.Image)(resources.GetObject("ForcePass.Image")));
             this.ForcePass.IsShowBorder = true;
-            this.ForcePass.Location = new System.Drawing.Point(393, 606);
-            this.ForcePass.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ForcePass.Location = new System.Drawing.Point(295, 485);
             this.ForcePass.MoveImage = ((System.Drawing.Image)(resources.GetObject("ForcePass.MoveImage")));
             this.ForcePass.Name = "ForcePass";
             this.ForcePass.NormalImage = ((System.Drawing.Image)(resources.GetObject("ForcePass.NormalImage")));
             this.ForcePass.Power = "ifWrite";
-            this.ForcePass.Size = new System.Drawing.Size(91, 38);
+            this.ForcePass.Size = new System.Drawing.Size(68, 30);
             this.ForcePass.TabIndex = 165;
             this.ForcePass.Text = "强制通过";
             this.ForcePass.UseVisualStyleBackColor = true;
@@ -547,13 +565,12 @@
             this.ForceRejection.Enabled = false;
             this.ForceRejection.Image = ((System.Drawing.Image)(resources.GetObject("ForceRejection.Image")));
             this.ForceRejection.IsShowBorder = true;
-            this.ForceRejection.Location = new System.Drawing.Point(393, 660);
-            this.ForceRejection.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.ForceRejection.Location = new System.Drawing.Point(295, 528);
             this.ForceRejection.MoveImage = ((System.Drawing.Image)(resources.GetObject("ForceRejection.MoveImage")));
             this.ForceRejection.Name = "ForceRejection";
             this.ForceRejection.NormalImage = ((System.Drawing.Image)(resources.GetObject("ForceRejection.NormalImage")));
             this.ForceRejection.Power = "ifWrite";
-            this.ForceRejection.Size = new System.Drawing.Size(91, 38);
+            this.ForceRejection.Size = new System.Drawing.Size(68, 30);
             this.ForceRejection.TabIndex = 164;
             this.ForceRejection.Text = "强制批退";
             this.ForceRejection.UseVisualStyleBackColor = true;
@@ -567,13 +584,12 @@
             this.WithdrawRejection.Enabled = false;
             this.WithdrawRejection.Image = ((System.Drawing.Image)(resources.GetObject("WithdrawRejection.Image")));
             this.WithdrawRejection.IsShowBorder = true;
-            this.WithdrawRejection.Location = new System.Drawing.Point(580, 660);
-            this.WithdrawRejection.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.WithdrawRejection.Location = new System.Drawing.Point(435, 528);
             this.WithdrawRejection.MoveImage = ((System.Drawing.Image)(resources.GetObject("WithdrawRejection.MoveImage")));
             this.WithdrawRejection.Name = "WithdrawRejection";
             this.WithdrawRejection.NormalImage = ((System.Drawing.Image)(resources.GetObject("WithdrawRejection.NormalImage")));
             this.WithdrawRejection.Power = "ifWrite";
-            this.WithdrawRejection.Size = new System.Drawing.Size(91, 38);
+            this.WithdrawRejection.Size = new System.Drawing.Size(68, 30);
             this.WithdrawRejection.TabIndex = 163;
             this.WithdrawRejection.Text = "撤销判退";
             this.WithdrawRejection.UseVisualStyleBackColor = true;
@@ -587,13 +603,12 @@
             this.BatchPass.Enabled = false;
             this.BatchPass.Image = ((System.Drawing.Image)(resources.GetObject("BatchPass.Image")));
             this.BatchPass.IsShowBorder = true;
-            this.BatchPass.Location = new System.Drawing.Point(41, 605);
-            this.BatchPass.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.BatchPass.Location = new System.Drawing.Point(31, 484);
             this.BatchPass.MoveImage = ((System.Drawing.Image)(resources.GetObject("BatchPass.MoveImage")));
             this.BatchPass.Name = "BatchPass";
             this.BatchPass.NormalImage = ((System.Drawing.Image)(resources.GetObject("BatchPass.NormalImage")));
             this.BatchPass.Power = "ifWrite";
-            this.BatchPass.Size = new System.Drawing.Size(91, 38);
+            this.BatchPass.Size = new System.Drawing.Size(68, 30);
             this.BatchPass.TabIndex = 162;
             this.BatchPass.Text = "批判过";
             this.BatchPass.UseVisualStyleBackColor = true;
@@ -606,77 +621,22 @@
             this.Clean.DownImage = ((System.Drawing.Image)(resources.GetObject("Clean.DownImage")));
             this.Clean.Image = ((System.Drawing.Image)(resources.GetObject("Clean.Image")));
             this.Clean.IsShowBorder = true;
-            this.Clean.Location = new System.Drawing.Point(1113, 642);
-            this.Clean.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.Clean.Location = new System.Drawing.Point(835, 514);
             this.Clean.MoveImage = ((System.Drawing.Image)(resources.GetObject("Clean.MoveImage")));
             this.Clean.Name = "Clean";
             this.Clean.NormalImage = ((System.Drawing.Image)(resources.GetObject("Clean.NormalImage")));
             this.Clean.Power = null;
-            this.Clean.Size = new System.Drawing.Size(85, 36);
+            this.Clean.Size = new System.Drawing.Size(64, 29);
             this.Clean.TabIndex = 159;
             this.Clean.Text = "清除";
             this.Clean.UseVisualStyleBackColor = true;
             this.Clean.Click += new System.EventHandler(this.Clean_Click);
             // 
-            // OperateResult
-            // 
-            this.OperateResult.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.OperateResult.Location = new System.Drawing.Point(1013, 214);
-            this.OperateResult.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
-            this.OperateResult.Name = "OperateResult";
-            this.OperateResult.Size = new System.Drawing.Size(279, 398);
-            this.OperateResult.TabIndex = 227;
-            this.OperateResult.Text = "";
-            // 
-            // ob_id
-            // 
-            this.ob_id.AllPower = null;
-            this.ob_id.BackColor = System.Drawing.Color.White;
-            this.ob_id.Enabled = false;
-            this.ob_id.ID = null;
-            this.ob_id.Location = new System.Drawing.Point(1012, 69);
-            this.ob_id.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
-            this.ob_id.Name = "ob_id";
-            this.ob_id.Power = null;
-            this.ob_id.Size = new System.Drawing.Size(195, 25);
-            this.ob_id.Str = null;
-            this.ob_id.Str1 = null;
-            this.ob_id.Str2 = null;
-            this.ob_id.TabIndex = 228;
-            this.ob_id.Tag = "NoAuto";
-            this.ob_id.Visible = false;
-            // 
-            // ob_source
-            // 
-            this.ob_source.AllPower = null;
-            this.ob_source.BackColor = System.Drawing.Color.White;
-            this.ob_source.Enabled = false;
-            this.ob_source.ID = null;
-            this.ob_source.Location = new System.Drawing.Point(1012, 94);
-            this.ob_source.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
-            this.ob_source.Name = "ob_source";
-            this.ob_source.Power = null;
-            this.ob_source.Size = new System.Drawing.Size(195, 25);
-            this.ob_source.Str = null;
-            this.ob_source.Str1 = null;
-            this.ob_source.Str2 = null;
-            this.ob_source.TabIndex = 229;
-            this.ob_source.Tag = "NoAuto";
-            // 
-            // ob_maxngacceptqty
-            // 
-            this.ob_maxngacceptqty.Location = new System.Drawing.Point(283, 532);
-            this.ob_maxngacceptqty.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
-            this.ob_maxngacceptqty.Name = "ob_maxngacceptqty";
-            this.ob_maxngacceptqty.Size = new System.Drawing.Size(257, 25);
-            this.ob_maxngacceptqty.TabIndex = 230;
-            this.ob_maxngacceptqty.Text = "0";
-            // 
             // OQC_BatchResultJudge
             // 
-            this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
+            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(1309, 706);
+            this.ClientSize = new System.Drawing.Size(982, 565);
             this.Controls.Add(this.ob_maxngacceptqty);
             this.Controls.Add(this.ob_source);
             this.Controls.Add(this.ob_id);
@@ -718,7 +678,6 @@
             this.Controls.Add(this.ob_ngqty_label);
             this.Controls.Add(this.oi_checkqty_label);
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
-            this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.Name = "OQC_BatchResultJudge";
             this.Tag = "OQC!BatchResultJudge";
             this.Text = "抽检批维护";

+ 3 - 3
UAS-MES/FunctionCode/OQC/OQC_BatchResultJudge.cs

@@ -289,10 +289,10 @@ namespace UAS_MES.OQC
                         sql.Add("update make set ma_madeqty=ma_madeqty-" + batchqty + " where ma_code='" + ob_makecode.Text + "'");
                     }
                     //获取上一步执行的工序
-                    string PastCode = dh.getFieldDataByCondition("makeserial", "ms_paststep", "ms_sncode='" + ms_sncode.Text + "'").ToString();
+                    string PastCode = dh.getFieldDataByCondition("makeserial", "SUBSTR(ms_paststep,0,INSTR(ms_paststep,',', -1, 1)-1) ms_paststep", "ms_sncode='" + ms_sncode.Text + "'").ToString();
                     string[] LastStepCode = PastCode.Split(',');
-                    sql.Add("update makeserial set ms_paststep='" + PastCode.Substring(0, PastCode.LastIndexOf(","))+"'");
-                    sql.Add("update makeserial set ms_stepcode='" + LastStepCode[LastStepCode.Length - 2] + "',ms_nextstepcode='"+User.CurrentStepCode+"',ms_status=1 where ms_checkno='" + ob_checkno.Text + "'");
+                    sql.Add("update makeserial set ms_paststep=(select distinct SUBSTR(ms_paststep,0,INSTR(ms_paststep,',', -1, 1)-1)  from makeserial where ms_checkno='" + ob_checkno.Text + "') where ms_checkno='" + ob_checkno.Text + "'");
+                    sql.Add("update makeserial set ms_stepcode='" + LastStepCode[LastStepCode.Length - 1] + "',ms_nextstepcode='" + User.CurrentStepCode + "',ms_status=1 where ms_checkno='" + ob_checkno.Text + "'");
                     sql.Add("update makecraftdetail set mcd_inqty=mcd_inqty-" + batchqty + ",mcd_outqty = mcd_outqty - " + batchqty + ",mcd_okqty = mcd_okqty -" + batchqty + " where mcd_macode='" + ob_makecode.Text + "' and mcd_stepcode='" + User.CurrentStepCode + "'");
                     dh.ExecuteSQLTran(sql.ToArray());
                 }

+ 25 - 10
UAS-MES/FunctionCode/OQC/OQC_SamplingDataCollection.cs

@@ -49,7 +49,6 @@ namespace UAS_MES.OQC
             if (ErrorMessage == "")
             {
                 BaseUtil.SetFormValue(Controls, dt[0]);
-                GetBatchTypeGridData();
                 dgvr.Clear();
             }
             else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red);
@@ -133,7 +132,7 @@ namespace UAS_MES.OQC
         {
             //只能操作检验中或者待检验的批次
             if (ob_status.Text == "待检验" || ob_status.Text == "检验中")
-            {
+            { 
                 if (!CheckSnCode())
                     return;
                 //判断检验项是否勾选,如勾选取出明细数据
@@ -159,7 +158,6 @@ namespace UAS_MES.OQC
                     for (int i = 0; i < TempForCheckType.Rows.Count; i++)
                     {
                         //将布尔值转换为0,-1
-                        Console.WriteLine(TempForCheckType.Rows[i]["ois_id"].ToString());
                         if (TempForCheckType.Rows[i]["ois_id"].ToString() != "" && TempForCheckType.Rows[i]["ois_id"].ToString() != "0")
                         {
                             ois_ifng_update.Add(TempForCheckType.Rows[i]["oi_ng"].ToString() == "True" ? "-1" : "0");
@@ -198,12 +196,18 @@ namespace UAS_MES.OQC
                         //如果主键为空,并且存在需要插入的数据则执行插入操作 
                         if (oi_itemcode_insert.Count > 0)
                         {
+                            string[] id = new string[oi_itemcode_insert.Count];
+                            for (int i = 0; i < id.Length; i++)
+                            {
+                                id[i] = dh.GetSEQ("OQCItemSamples_SEQ");
+                            }
                             sql.Clear();
-                            sql.Append("insert into OQCItemSamples (ois_id,ois_checkno,ois_makecode, ois_sncode,ois_projectcode,ois_itemcode,");
-                            sql.Append("ois_ifng,ois_defectlevel,ois_remark)values(OQCItemSamples_SEQ.nextval,'" + ob_checkno.Text + "',");
-                            sql.Append("'" + ob_makecode.Text + "','" + sncode.Text + "','" + ob_projectcode.Text + "',:ois_itemcode,:ois_ifng,:ois_defectlevel,:ois_remark)");
-                            dh.BatchInsert(sql.GetString(), new string[] { "ois_itemcode", "ois_ifng", "ois_defectlevel", "ois_remark" },
-                                oi_itemcode_insert.ToArray(), ois_ifng_insert.ToArray(), ois_defectlevel_insert.ToArray(), ois_remark_insert.ToArray());
+                            sql.Append("insert when (not exists (select ois_id from OQCItemSamples where ois_checkno='"+ob_checkno.Text+"' and ois_sncode='"+sncode.Text+ "' and ois_itemcode =:ois_itemcode)) then ");
+                            sql.Append("into OQCItemSamples (ois_id,ois_checkno,ois_makecode, ois_sncode,ois_projectcode,ois_itemcode,");
+                            sql.Append("ois_ifng,ois_defectlevel,ois_remark)select :id,'" + ob_checkno.Text + "',");
+                            sql.Append("'" + ob_makecode.Text + "','" + sncode.Text + "','" + ob_projectcode.Text + "',:ois_itemcode,:ois_ifng,:ois_defectlevel,:ois_remark from dual");
+                            dh.BatchInsert(sql.GetString(), new string[] { "ois_itemcode","id", "ois_itemcode", "ois_ifng", "ois_defectlevel", "ois_remark" },
+                                 oi_itemcode_insert.ToArray(), id, oi_itemcode_insert.ToArray(), ois_ifng_insert.ToArray(), ois_defectlevel_insert.ToArray(), ois_remark_insert.ToArray());
                         }
                         //采集不良信息
                         List<string> bc_code = new List<string>();
@@ -228,7 +232,10 @@ namespace UAS_MES.OQC
                         //更新批次中的合格数不合格数:用抽检批检验项目表获取最大的抽检数和不合格数
                         dh.ExecuteSql("update OQCBATCH set (ob_ngqty,ob_okqty)=(select nvl(max(oi_ngqty),0),max(oi_checkqty)-nvl(max(oi_ngqty),0) from OQCItems where oi_checkno ='" + ob_checkno.Text + "') where ob_checkno ='" + ob_checkno.Text + "'", "update");
                         OperateResult.AppendText(">>操作成功\n", Color.Green);
-                        GetBatchTypeGridData();
+                        GetBatch.PerformClick();
+                        CheckTypeDGV.DataSource = null;
+                        ChoosedDGV.DataSource = null;
+                        sncode.Text = "";
                         TempForCheckType.Clear();
                     }
                     else OperateResult.AppendText(">>含有未通过项请勾选不良明细\n", Color.Red);
@@ -368,7 +375,15 @@ namespace UAS_MES.OQC
                 textcell.Value = "检验状态";
                 headerRow.Cells.Add(textcell);
                 headerRow.ReadOnly = true;
-                CollapseDataGridViewRow cl = (CollapseDataGridViewRow)(CheckTypeDGV.Rows[e.RowIndex]);
+                CollapseDataGridViewRow cl = new CollapseDataGridViewRow() ;
+                try
+                {
+                    cl = (CollapseDataGridViewRow)(CheckTypeDGV.Rows[e.RowIndex]);
+                }
+                catch {
+
+                }
+              
                 cl.Rows.Add(headerRow);
 
                 for (int i = 0; i < dt.Rows.Count; i++)

+ 1 - 1
UAS-MES/UAS-MES.csproj

@@ -41,7 +41,7 @@
     <MinimumRequiredVersion>1.0.0.201</MinimumRequiredVersion>
     <CreateWebPageOnPublish>true</CreateWebPageOnPublish>
     <WebPage>publish.htm</WebPage>
-    <ApplicationRevision>250</ApplicationRevision>
+    <ApplicationRevision>252</ApplicationRevision>
     <ApplicationVersion>1.0.0.%2a</ApplicationVersion>
     <UseApplicationTrust>true</UseApplicationTrust>
     <CreateDesktopShortcut>true</CreateDesktopShortcut>