shim 8 سال پیش
والد
کامیت
de8ee0384c
2فایلهای تغییر یافته به همراه18 افزوده شده و 18 حذف شده
  1. 9 9
      UAS-MES/FunctionCode/Make/Make_FuselageLabelPrint.cs
  2. 9 9
      UAS-MES/FunctionCode/Make/Make_PalletWeigh.cs

+ 9 - 9
UAS-MES/FunctionCode/Make/Make_FuselageLabelPrint.cs

@@ -44,14 +44,7 @@ namespace UAS_MES.Make
             sncode.Focus();
             asc.controllInitializeSize(this);
             OperateResult.AppendText(">>请输入SN\n", Color.Green);
-            try
-            {
-                InitPrint = new Thread(InPrint);
-            }
-            catch (Exception ex)
-            {
-                MessageBox.Show(ex.Message);
-            }
+            InitPrint = new Thread(InPrint);
             SetLoadingWindow stw = new SetLoadingWindow(InitPrint, "初始化打印程序");
             BaseUtil.SetFormCenter(stw);
             stw.ShowDialog();
@@ -59,7 +52,14 @@ namespace UAS_MES.Make
 
         private void InPrint()
         {
-            lbl = new ApplicationClass();
+            try
+            {
+                lbl = new ApplicationClass();
+            }
+            catch (Exception ex)
+            {
+                MessageBox.Show("未安装codesoft");
+            }
         }
 
         private void sn_code_KeyDown(object sender, KeyEventArgs e)

+ 9 - 9
UAS-MES/FunctionCode/Make/Make_PalletWeigh.cs

@@ -59,21 +59,21 @@ namespace UAS_MES.Make
             ComList.Text = Properties.Settings.Default.PortName;
             BaudRate.Text = Properties.Settings.Default.BaudRate;
             dh = new DataHelper();
-            try
-            {
-                InitPrint = new Thread(InPrint);
-            }
-            catch (Exception ex)
-            {
-                MessageBox.Show(ex.Message);
-            }
+            InitPrint = new Thread(InPrint);
             SetLoadingWindow stw = new SetLoadingWindow(InitPrint, "初始化打印程序");
             BaseUtil.SetFormCenter(stw);
             stw.ShowDialog();
         }
         private void InPrint()
         {
-            lbl = new ApplicationClass();
+            try
+            {
+                lbl = new ApplicationClass();
+            }
+            catch (Exception ex)
+            {
+                MessageBox.Show("未安装codesoft");
+            }
         }
         private void Make_PalletWeigh_SizeChanged(object sender, EventArgs e)
         {