Browse Source

打印插件连接至共享打印机打印机名错误的BUG调整

Hcsy 6 years ago
parent
commit
e20c84c3d4

+ 15 - 15
UAS_PRINT/Form2.Designer.cs

@@ -29,19 +29,19 @@
         private void InitializeComponent()
         {
             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form2));
-            this.MyNotifyIcon = new System.Windows.Forms.NotifyIcon();
+            this.提示 = new System.Windows.Forms.NotifyIcon();
             this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip();
-            this.退出ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
             this.打开根目录ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+            this.退出ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
             this.contextMenuStrip1.SuspendLayout();
             this.SuspendLayout();
             // 
-            // MyNotifyIcon
+            // 提示
             // 
-            this.MyNotifyIcon.ContextMenuStrip = this.contextMenuStrip1;
-            this.MyNotifyIcon.Icon = ((System.Drawing.Icon)(resources.GetObject("MyNotifyIcon.Icon")));
-            this.MyNotifyIcon.Text = "notifyIcon1";
-            this.MyNotifyIcon.Visible = true;
+            this.提示.ContextMenuStrip = this.contextMenuStrip1;
+            this.提示.Icon = ((System.Drawing.Icon)(resources.GetObject("提示.Icon")));
+            this.提示.Text = "提示";
+            this.提示.Visible = true;
             // 
             // contextMenuStrip1
             // 
@@ -51,13 +51,6 @@
             this.contextMenuStrip1.Name = "contextMenuStrip1";
             this.contextMenuStrip1.Size = new System.Drawing.Size(153, 70);
             // 
-            // 退出ToolStripMenuItem
-            // 
-            this.退出ToolStripMenuItem.Name = "退出ToolStripMenuItem";
-            this.退出ToolStripMenuItem.Size = new System.Drawing.Size(152, 22);
-            this.退出ToolStripMenuItem.Text = "退出";
-            this.退出ToolStripMenuItem.Click += new System.EventHandler(this.退出ToolStripMenuItem_Click);
-            // 
             // 打开根目录ToolStripMenuItem
             // 
             this.打开根目录ToolStripMenuItem.Name = "打开根目录ToolStripMenuItem";
@@ -65,6 +58,13 @@
             this.打开根目录ToolStripMenuItem.Text = "打开根目录";
             this.打开根目录ToolStripMenuItem.Click += new System.EventHandler(this.打开根目录ToolStripMenuItem_Click);
             // 
+            // 退出ToolStripMenuItem
+            // 
+            this.退出ToolStripMenuItem.Name = "退出ToolStripMenuItem";
+            this.退出ToolStripMenuItem.Size = new System.Drawing.Size(152, 22);
+            this.退出ToolStripMenuItem.Text = "退出";
+            this.退出ToolStripMenuItem.Click += new System.EventHandler(this.退出ToolStripMenuItem_Click);
+            // 
             // Form2
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
@@ -82,7 +82,7 @@
 
         #endregion
 
-        private System.Windows.Forms.NotifyIcon MyNotifyIcon;
+        private System.Windows.Forms.NotifyIcon 提示;
         private System.Windows.Forms.ContextMenuStrip contextMenuStrip1;
         private System.Windows.Forms.ToolStripMenuItem 退出ToolStripMenuItem;
         private System.Windows.Forms.ToolStripMenuItem 打开根目录ToolStripMenuItem;

+ 1 - 1
UAS_PRINT/Form2.cs

@@ -37,7 +37,7 @@ namespace UAS_PRINT
 
             ThrednHttpPostRequest = new Thread(new ThreadStart(httpPostRequestHandle));
             ThrednHttpPostRequest.Start();
-            MyNotifyIcon.ShowBalloonTip(30,"提示","程序启动",ToolTipIcon.Info);
+            提示.ShowBalloonTip(30,"提示","程序启动",ToolTipIcon.Info);
         }
 
 

+ 2 - 2
UAS_PRINT/Form2.resx

@@ -117,14 +117,14 @@
   <resheader name="writer">
     <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
   </resheader>
-  <metadata name="MyNotifyIcon.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
+  <metadata name="提示.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
     <value>17, 17</value>
   </metadata>
   <metadata name="contextMenuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
     <value>149, 17</value>
   </metadata>
   <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
-  <data name="MyNotifyIcon.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+  <data name="提示.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         AAABAAsAMDAAAAEACACoDgAAtgAAACAgAAABAAgAqAgAAF4PAAAYGAAAAQAIAMgGAAAGGAAAEBAAAAEA
         CABoBQAAzh4AAAAAAAABACAAS1cAADYkAACAgAAAAQAgACgIAQCBewAAQEAAAAEAIAAoQgAAqYMBADAw

+ 1 - 1
UAS_PRINT/PrintHandler.cs

@@ -220,7 +220,7 @@ namespace UAS_PRINT
                 Report.RegisterData(dt, label_type);
                 Report.GetDataSource(label_type).Enabled = true;
                 Report.PrintSettings.ShowDialog = false;
-                Report.PrintSettings.Printer = chooseprintername;
+                Report.PrintSettings.Printer = chooseprintername.Replace("\\\\","\\");
                 Report.Print();
             }
             catch

+ 25 - 0
UAS_PRINT/采购验收条码打印.frx

@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Report ScriptLanguage="CSharp" ReportInfo.Created="10/19/2018 11:43:13" ReportInfo.Modified="10/26/2018 13:54:25" ReportInfo.CreatorVersion="2016.1.0.0">
+  <Styles>
+    <Style Name="格式1" Font="宋体, 8pt"/>
+  </Styles>
+  <Dictionary>
+    <OdbcDataConnection Name="Connection" ConnectionString="rijcmlq4T7ij3QEI356NBqYh9OCyJFC+4ve8MyX68hS9dp4KxtjsXmhMR5qHfWU7SD1aL6rtQ6veEInPXeBljObwgoETiL5P3lLDhCbg0cUCPa9CuOABr92GWnu+Z5vBcfzS8HrJAOBBcDODKQUJus9TGudO8ARvED8UkKj0en0ZcKe4dj09XgVxA1pioytn0IYDL/zOFU04YpURKHW6Tx+lE9WTOW5wZsdr27/idSqAYrKjs7Ad2fI/JfbJJP07iCmtxY1j+x5VbAvBa/yiOreXnYYUg==">
+      <TableDataSource Name="Table1" Alias="BARCODEIO_PRINT_VIEW" DataType="System.Int32" Enabled="true" SelectCommand="SELECT * FROM BARCODEIO_PRINT_VIEW">
+        <Column Name="BI_BARCODE" DataType="System.String"/>
+        <Column Name="BI_PRODCODE" DataType="System.String"/>
+        <Column Name="BI_INQTY" DataType="System.Double"/>
+        <Column Name="PR_ORISPECCODE" DataType="System.String"/>
+      </TableDataSource>
+    </OdbcDataConnection>
+  </Dictionary>
+  <ReportPage Name="Page1" PaperWidth="100" PaperHeight="40" LeftMargin="0" TopMargin="0" RightMargin="0" BottomMargin="0" FirstPageSource="4" OtherPagesSource="4" Guides="28.35,325.55,122.85,217.35,311.85,321.3">
+    <DataBand Name="Data1" Width="378" Height="151.2" FirstRowStartsNewPage="true" Guides="28.35,85.05,103.95,122.85,9.45">
+      <TextObject Name="Text1" Left="29.3" Top="9.45" Width="296.25" Height="18.9" Text="[BARCODEIO_PRINT_VIEW.BI_BARCODE]" HorzAlign="Center" Font="宋体, 9pt"/>
+      <BarcodeObject Name="Barcode1" Left="26.15" Top="37.8" Width="299.4" Height="47.25" AutoSize="false" DataColumn="BARCODEIO_PRINT_VIEW.BI_BARCODE" Text="" ShowText="false" Barcode.CalcCheckSum="false"/>
+      <TextObject Name="Text2" Left="28.35" Top="94.5" Width="94.5" Height="18.9" Text="[BARCODEIO_PRINT_VIEW.BI_PRODCODE]" Font="宋体, 9pt"/>
+      <TextObject Name="Text3" Left="122.85" Top="94.5" Width="94.5" Height="18.9" Text="[BARCODEIO_PRINT_VIEW.PR_ORISPECCODE]" Font="宋体, 9pt"/>
+      <TextObject Name="Text4" Left="217.35" Top="94.5" Width="108.2" Height="18.9" Text="[BARCODEIO_PRINT_VIEW.BI_INQTY]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Font="宋体, 9pt" Trimming="EllipsisCharacter"/>
+    </DataBand>
+  </ReportPage>
+</Report>