Browse Source

条码打印指令格式问题修改

Hcsy 7 years ago
parent
commit
a18906e799
2 changed files with 5 additions and 2 deletions
  1. 4 1
      UAS_Web/PrinterList.Designer.cs
  2. 1 1
      UAS_Web/tool/RequestHandler.cs

+ 4 - 1
UAS_Web/PrinterList.Designer.cs

@@ -59,10 +59,13 @@
             this.ClientSize = new System.Drawing.Size(321, 170);
             this.Controls.Add(this.Confirm);
             this.Controls.Add(this.Printer);
+            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow;
             this.Name = "PrinterList";
+            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
             this.Text = "打印机列表";
+            this.TopMost = true;
             this.Load += new System.EventHandler(this.PrinterList_Load);
-            this.ResumeLayout(false);
+            this.ResumeLayout(true);
 
         }
 

+ 1 - 1
UAS_Web/tool/RequestHandler.cs

@@ -75,7 +75,7 @@ namespace UAS_Web.tool
                     //获取所有的打印格式数据
                     if (data.ContainsKey("data"))
                     {
-                        string PrintCode = data["data"].ToString();
+                        string PrintCode = data["data"].ToString().Replace(" ", "").Replace("\"", "");
                         List<string> PrintList = new List<string>();
                         int PrintTime = Regex.Matches(PrintCode, "XA").Count;
                         for (int i = 0; i < PrintTime; i++)