浏览代码

修改代码格式

章政 8 年之前
父节点
当前提交
517391ce14

+ 48 - 59
UAS-MES/FunctionCode/Make/Make_ColorBoxLabelPrint.Designer.cs

@@ -54,20 +54,19 @@
             // 
             this.PrintLabel.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
             this.PrintLabel.FormattingEnabled = true;
-            this.PrintLabel.Location = new System.Drawing.Point(1048, 111);
-            this.PrintLabel.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.PrintLabel.Location = new System.Drawing.Point(786, 89);
+            this.PrintLabel.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
             this.PrintLabel.Name = "PrintLabel";
-            this.PrintLabel.Size = new System.Drawing.Size(178, 23);
+            this.PrintLabel.Size = new System.Drawing.Size(134, 20);
             this.PrintLabel.TabIndex = 181;
             // 
             // label2
             // 
             this.label2.AutoSize = true;
             this.label2.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label2.Location = new System.Drawing.Point(945, 48);
-            this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label2.Location = new System.Drawing.Point(709, 38);
             this.label2.Name = "label2";
-            this.label2.Size = new System.Drawing.Size(72, 27);
+            this.label2.Size = new System.Drawing.Size(58, 21);
             this.label2.TabIndex = 180;
             this.label2.Text = "打印机";
             // 
@@ -75,10 +74,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.Location = new System.Drawing.Point(945, 111);
-            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label1.Location = new System.Drawing.Point(709, 89);
             this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(52, 27);
+            this.label1.Size = new System.Drawing.Size(42, 21);
             this.label1.TabIndex = 179;
             this.label1.Text = "标签";
             // 
@@ -86,10 +84,9 @@
             // 
             this.pr_detail_label.AutoSize = true;
             this.pr_detail_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_detail_label.Location = new System.Drawing.Point(597, 50);
-            this.pr_detail_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_detail_label.Location = new System.Drawing.Point(448, 40);
             this.pr_detail_label.Name = "pr_detail_label";
-            this.pr_detail_label.Size = new System.Drawing.Size(92, 27);
+            this.pr_detail_label.Size = new System.Drawing.Size(74, 21);
             this.pr_detail_label.TabIndex = 171;
             this.pr_detail_label.Text = "产品名称";
             // 
@@ -99,10 +96,9 @@
             | System.Windows.Forms.AnchorStyles.Left)));
             this.sncode_label.AutoSize = true;
             this.sncode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.sncode_label.Location = new System.Drawing.Point(13, 559);
-            this.sncode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.sncode_label.Location = new System.Drawing.Point(10, 447);
             this.sncode_label.Name = "sncode_label";
-            this.sncode_label.Size = new System.Drawing.Size(72, 27);
+            this.sncode_label.Size = new System.Drawing.Size(58, 21);
             this.sncode_label.TabIndex = 170;
             this.sncode_label.Text = "序列号";
             // 
@@ -110,10 +106,9 @@
             // 
             this.label4.AutoSize = true;
             this.label4.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label4.Location = new System.Drawing.Point(597, 111);
-            this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label4.Location = new System.Drawing.Point(448, 89);
             this.label4.Name = "label4";
-            this.label4.Size = new System.Drawing.Size(92, 27);
+            this.label4.Size = new System.Drawing.Size(74, 21);
             this.label4.TabIndex = 167;
             this.label4.Text = "打印张数";
             // 
@@ -121,10 +116,9 @@
             // 
             this.mcd_remainqty_label.AutoSize = true;
             this.mcd_remainqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_remainqty_label.Location = new System.Drawing.Point(305, 111);
-            this.mcd_remainqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.mcd_remainqty_label.Location = new System.Drawing.Point(229, 89);
             this.mcd_remainqty_label.Name = "mcd_remainqty_label";
-            this.mcd_remainqty_label.Size = new System.Drawing.Size(72, 27);
+            this.mcd_remainqty_label.Size = new System.Drawing.Size(58, 21);
             this.mcd_remainqty_label.TabIndex = 166;
             this.mcd_remainqty_label.Text = "剩余数";
             // 
@@ -132,10 +126,9 @@
             // 
             this.mcd_okqty_label.AutoSize = true;
             this.mcd_okqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_okqty_label.Location = new System.Drawing.Point(13, 111);
-            this.mcd_okqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.mcd_okqty_label.Location = new System.Drawing.Point(10, 89);
             this.mcd_okqty_label.Name = "mcd_okqty_label";
-            this.mcd_okqty_label.Size = new System.Drawing.Size(92, 27);
+            this.mcd_okqty_label.Size = new System.Drawing.Size(74, 21);
             this.mcd_okqty_label.TabIndex = 165;
             this.mcd_okqty_label.Text = "打印计数";
             // 
@@ -143,10 +136,9 @@
             // 
             this.pr_code_label.AutoSize = true;
             this.pr_code_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_code_label.Location = new System.Drawing.Point(305, 50);
-            this.pr_code_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_code_label.Location = new System.Drawing.Point(229, 40);
             this.pr_code_label.Name = "pr_code_label";
-            this.pr_code_label.Size = new System.Drawing.Size(92, 27);
+            this.pr_code_label.Size = new System.Drawing.Size(74, 21);
             this.pr_code_label.TabIndex = 164;
             this.pr_code_label.Text = "产品编号";
             // 
@@ -154,29 +146,27 @@
             // 
             this.ms_makecode_label.AutoSize = true;
             this.ms_makecode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ms_makecode_label.Location = new System.Drawing.Point(13, 50);
-            this.ms_makecode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ms_makecode_label.Location = new System.Drawing.Point(10, 40);
             this.ms_makecode_label.Name = "ms_makecode_label";
-            this.ms_makecode_label.Size = new System.Drawing.Size(92, 27);
+            this.ms_makecode_label.Size = new System.Drawing.Size(74, 21);
             this.ms_makecode_label.TabIndex = 163;
             this.ms_makecode_label.Text = "归属工单";
             // 
             // Printer
             // 
-            this.Printer.Location = new System.Drawing.Point(1048, 48);
-            this.Printer.Margin = new System.Windows.Forms.Padding(5);
+            this.Printer.Location = new System.Drawing.Point(786, 38);
+            this.Printer.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.Printer.Name = "Printer";
-            this.Printer.Size = new System.Drawing.Size(178, 31);
+            this.Printer.Size = new System.Drawing.Size(134, 25);
             this.Printer.TabIndex = 178;
             // 
             // mcd_remainqty
             // 
             this.mcd_remainqty.AutoSize = true;
             this.mcd_remainqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_remainqty.Location = new System.Drawing.Point(423, 111);
-            this.mcd_remainqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.mcd_remainqty.Location = new System.Drawing.Point(317, 89);
             this.mcd_remainqty.Name = "mcd_remainqty";
-            this.mcd_remainqty.Size = new System.Drawing.Size(24, 27);
+            this.mcd_remainqty.Size = new System.Drawing.Size(19, 21);
             this.mcd_remainqty.TabIndex = 177;
             this.mcd_remainqty.Text = "0";
             // 
@@ -184,32 +174,33 @@
             // 
             this.mcd_okqty.AutoSize = true;
             this.mcd_okqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_okqty.Location = new System.Drawing.Point(137, 111);
-            this.mcd_okqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.mcd_okqty.Location = new System.Drawing.Point(103, 89);
             this.mcd_okqty.Name = "mcd_okqty";
-            this.mcd_okqty.Size = new System.Drawing.Size(24, 27);
+            this.mcd_okqty.Size = new System.Drawing.Size(19, 21);
             this.mcd_okqty.TabIndex = 176;
             this.mcd_okqty.Text = "0";
             // 
             // pr_code
             // 
             this.pr_code.AutoSize = true;
+            this.pr_code.CutLength = null;
             this.pr_code.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_code.Location = new System.Drawing.Point(423, 50);
-            this.pr_code.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_code.Location = new System.Drawing.Point(317, 40);
+            this.pr_code.MaximumSize = new System.Drawing.Size(150, 0);
             this.pr_code.Name = "pr_code";
-            this.pr_code.Size = new System.Drawing.Size(0, 27);
+            this.pr_code.Size = new System.Drawing.Size(0, 21);
             this.pr_code.TabIndex = 175;
             this.pr_code.TextChanged += new System.EventHandler(this.pr_code_TextChanged);
             // 
             // pr_detail
             // 
             this.pr_detail.AutoSize = true;
+            this.pr_detail.CutLength = null;
             this.pr_detail.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_detail.Location = new System.Drawing.Point(714, 52);
-            this.pr_detail.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_detail.Location = new System.Drawing.Point(536, 42);
+            this.pr_detail.MaximumSize = new System.Drawing.Size(150, 0);
             this.pr_detail.Name = "pr_detail";
-            this.pr_detail.Size = new System.Drawing.Size(0, 27);
+            this.pr_detail.Size = new System.Drawing.Size(0, 21);
             this.pr_detail.TabIndex = 174;
             // 
             // PrintNum
@@ -217,16 +208,16 @@
             this.PrintNum.AllPower = null;
             this.PrintNum.BackColor = System.Drawing.Color.White;
             this.PrintNum.ID = null;
-            this.PrintNum.Location = new System.Drawing.Point(714, 111);
-            this.PrintNum.Margin = new System.Windows.Forms.Padding(4);
+            this.PrintNum.Location = new System.Drawing.Point(536, 89);
             this.PrintNum.Name = "PrintNum";
             this.PrintNum.Negative = false;
             this.PrintNum.Power = null;
-            this.PrintNum.Size = new System.Drawing.Size(198, 25);
+            this.PrintNum.Size = new System.Drawing.Size(150, 21);
             this.PrintNum.Str = null;
             this.PrintNum.Str1 = null;
             this.PrintNum.Str2 = null;
             this.PrintNum.TabIndex = 172;
+            this.PrintNum.Text = "1";
             // 
             // sncode
             // 
@@ -235,11 +226,10 @@
             | System.Windows.Forms.AnchorStyles.Left)));
             this.sncode.BackColor = System.Drawing.Color.White;
             this.sncode.ID = null;
-            this.sncode.Location = new System.Drawing.Point(132, 560);
-            this.sncode.Margin = new System.Windows.Forms.Padding(4);
+            this.sncode.Location = new System.Drawing.Point(99, 448);
             this.sncode.Name = "sncode";
             this.sncode.Power = null;
-            this.sncode.Size = new System.Drawing.Size(260, 25);
+            this.sncode.Size = new System.Drawing.Size(196, 21);
             this.sncode.Str = null;
             this.sncode.Str1 = null;
             this.sncode.Str2 = null;
@@ -250,10 +240,9 @@
             // 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(18, 161);
-            this.OperateResult.Margin = new System.Windows.Forms.Padding(4);
+            this.OperateResult.Location = new System.Drawing.Point(14, 129);
             this.OperateResult.Name = "OperateResult";
-            this.OperateResult.Size = new System.Drawing.Size(940, 380);
+            this.OperateResult.Size = new System.Drawing.Size(706, 305);
             this.OperateResult.TabIndex = 168;
             this.OperateResult.Text = "";
             // 
@@ -261,16 +250,17 @@
             // 
             this.ma_code.AutoSize = true;
             this.ma_code.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ma_code.Location = new System.Drawing.Point(137, 52);
+            this.ma_code.Location = new System.Drawing.Point(103, 42);
+            this.ma_code.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.ma_code.Name = "ma_code";
-            this.ma_code.Size = new System.Drawing.Size(0, 27);
+            this.ma_code.Size = new System.Drawing.Size(0, 21);
             this.ma_code.TabIndex = 183;
             // 
             // Make_ColorBoxLabelPrint
             // 
-            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(1250, 600);
+            this.ClientSize = new System.Drawing.Size(938, 480);
             this.Controls.Add(this.ma_code);
             this.Controls.Add(this.PrintLabel);
             this.Controls.Add(this.label2);
@@ -291,7 +281,6 @@
             this.Controls.Add(this.pr_code_label);
             this.Controls.Add(this.ms_makecode_label);
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
-            this.Margin = new System.Windows.Forms.Padding(4);
             this.Name = "Make_ColorBoxLabelPrint";
             this.Tag = "Make!ColorBoxLabelPrint";
             this.Text = "标签打印";

+ 8 - 0
UAS-MES/FunctionCode/Make/Make_ColorBoxLabelPrint.cs

@@ -32,11 +32,14 @@ namespace UAS_MES.Make
         string macode;
         //当前提示的索引
         int RemainIndex = 0;
+
         ApplicationClass lbl;
+
         public Make_ColorBoxLabelPrint()
         {
             InitializeComponent();
         }
+
         private void Make_ColorBoxLabelPrint_Load(object sender, EventArgs e)
         {
             dh = new DataHelper();
@@ -44,6 +47,7 @@ namespace UAS_MES.Make
             asc.controllInitializeSize(this);
             lbl = new ApplicationClass();
         }
+
         private void sn_code_KeyDown(object sender, KeyEventArgs e)
         {
             if (e.KeyCode == Keys.Enter)
@@ -135,6 +139,7 @@ namespace UAS_MES.Make
                 }
             }
         }
+
         //根据产品编号获取打印模板
         private void pr_code_TextChanged(object sender, EventArgs e)
         {
@@ -148,14 +153,17 @@ namespace UAS_MES.Make
                 BaseUtil.GetPrintLabel(dt.Rows[i]["pl_labelname"].ToString(), dt.Rows[i]["pl_labelurl"].ToString(), dt.Rows[i]["pl_indate"].ToString());
             }
         }
+
         private void Make_ColorBoxLabelPrint_Activated(object sender, EventArgs e)
         {
             sncode.Focus();
         }
+
         private void Make_ColorBoxLabelPrint_FormClosing(object sender, FormClosingEventArgs e)
         {
             lbl.Quit();
         }
+
         private void Make_ColorBoxLabelPrint_SizeChanged(object sender, EventArgs e)
         {
             asc.controlAutoSize(this);