瀏覽代碼

V1.2.6
修改配置文件路径为C:\\Temp

Dail 1 年之前
父節點
當前提交
3f07f78f1a

二進制
.vs/Welling_Motor_Debug_Tool/v17/.suo


+ 13 - 1
Welling_Motor_Debug_Tool/Form1.Designer.cs

@@ -405,6 +405,7 @@ namespace Welling_Motor_Debug_Tool
             this.textBox_FacModeSensorCal2 = new System.Windows.Forms.TextBox();
             this.groupBox19 = new System.Windows.Forms.GroupBox();
             this.button_FacModeInit = new System.Windows.Forms.Button();
+            this.tabPage_ProductMode = new System.Windows.Forms.TabPage();
             this.label23 = new System.Windows.Forms.Label();
             this.label_RecCount = new System.Windows.Forms.Label();
             this.timer_1s = new System.Windows.Forms.Timer(this.components);
@@ -1463,6 +1464,7 @@ namespace Welling_Motor_Debug_Tool
             this.tabControl1.Controls.Add(this.tabPage_OBC);
             this.tabControl1.Controls.Add(this.tabPage_RAMorFLASH);
             this.tabControl1.Controls.Add(this.tabPage_FactoryMode);
+            this.tabControl1.Controls.Add(this.tabPage_ProductMode);
             this.tabControl1.Location = new System.Drawing.Point(10, 27);
             this.tabControl1.Name = "tabControl1";
             this.tabControl1.SelectedIndex = 0;
@@ -3518,7 +3520,7 @@ namespace Welling_Motor_Debug_Tool
             this.tabPage_FactoryMode.Name = "tabPage_FactoryMode";
             this.tabPage_FactoryMode.Size = new System.Drawing.Size(990, 315);
             this.tabPage_FactoryMode.TabIndex = 10;
-            this.tabPage_FactoryMode.Text = "生产模式";
+            this.tabPage_FactoryMode.Text = "样机配置";
             // 
             // button_ScanCode
             // 
@@ -4457,6 +4459,15 @@ namespace Welling_Motor_Debug_Tool
             this.button_FacModeInit.UseVisualStyleBackColor = false;
             this.button_FacModeInit.Click += new System.EventHandler(this.button_FacModeInit_Click);
             // 
+            // tabPage_ProductMode
+            // 
+            this.tabPage_ProductMode.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192)))));
+            this.tabPage_ProductMode.Location = new System.Drawing.Point(4, 30);
+            this.tabPage_ProductMode.Name = "tabPage_ProductMode";
+            this.tabPage_ProductMode.Size = new System.Drawing.Size(990, 315);
+            this.tabPage_ProductMode.TabIndex = 11;
+            this.tabPage_ProductMode.Text = "工厂模式";
+            // 
             // label23
             // 
             this.label23.AutoSize = true;
@@ -5093,5 +5104,6 @@ namespace Welling_Motor_Debug_Tool
         private Button Button_FacModeSetNum;
         private Button button_FacModeSetName;
         private Button button_ScanCode;
+        private TabPage tabPage_ProductMode;
     }
 }

+ 6 - 7
Welling_Motor_Debug_Tool/Form1.cs

@@ -23,7 +23,7 @@ namespace Welling_Motor_Debug_Tool
         ftp myFtp = new ftp();
         //本地存储数据路径
         string LocalPath = "";
-        string ConfigFileName = "";
+        string ConfigFileName = "C:\\Temp\\Config.ttcfg";
         //MC运行信息超时计数
         bool MC_RunInfo_Refresh = false;
         ushort MC_RunInfo_Refresh_Cnt = 0;
@@ -102,7 +102,6 @@ namespace Welling_Motor_Debug_Tool
         {
             InitializeComponent();
             //检查配置文件
-            ConfigFileName = Directory.GetCurrentDirectory() + "\\" + "Config.ttcfg";
             if (File.Exists(ConfigFileName)) //存在配置文件,导入配置信息
             {
                 //打开文件
@@ -182,18 +181,18 @@ namespace Welling_Motor_Debug_Tool
                     label_Server_ComStatus.Text = "网络断开";
                     label_ServerStatus.BackColor = Color.Red;
                     myFtp.IsNetConnected = false;
-                    if (允许ToolStripMenuItem.Checked == true) //离线使用
+                    if (允许ToolStripMenuItem.Checked == false) ///不允许离线使用,自动关闭 
                     {
                         timer_1s.Enabled = false;
-                        MessageBox.Show("网络断开,离线使用!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("网络断开,将自动关闭!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                         timer_1s.Enabled = true;
+                        this.Close();                        
                     }
-                    else //不允许离线使用,自动关闭 
+                    else //离线使用
                     {
                         timer_1s.Enabled = false;
-                        MessageBox.Show("网络断开,将自动关闭!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Warning);
+                        MessageBox.Show("网络断开,离线使用!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         timer_1s.Enabled = true;
-                        this.Close();
                     }
                 }
             }));

+ 4 - 3
Welling_Motor_Debug_Tool/Scan.Designer.cs

@@ -51,7 +51,7 @@
             // 
             this.textBox_Code.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(192)))));
             this.textBox_Code.Location = new System.Drawing.Point(28, 63);
-            this.textBox_Code.Margin = new System.Windows.Forms.Padding(6, 6, 6, 6);
+            this.textBox_Code.Margin = new System.Windows.Forms.Padding(6);
             this.textBox_Code.Name = "textBox_Code";
             this.textBox_Code.Size = new System.Drawing.Size(449, 33);
             this.textBox_Code.TabIndex = 1;
@@ -60,7 +60,7 @@
             // 
             this.button_Enter.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(192)))), ((int)(((byte)(128)))));
             this.button_Enter.Location = new System.Drawing.Point(486, 63);
-            this.button_Enter.Margin = new System.Windows.Forms.Padding(6, 6, 6, 6);
+            this.button_Enter.Margin = new System.Windows.Forms.Padding(6);
             this.button_Enter.Name = "button_Enter";
             this.button_Enter.Size = new System.Drawing.Size(80, 33);
             this.button_Enter.TabIndex = 2;
@@ -99,11 +99,12 @@
             this.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
             this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
-            this.Margin = new System.Windows.Forms.Padding(6, 6, 6, 6);
+            this.Margin = new System.Windows.Forms.Padding(6);
             this.MaximizeBox = false;
             this.Name = "Scan";
             this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
             this.Text = "扫码";
+            this.Load += new System.EventHandler(this.Scan_Load);
             this.statusStrip1.ResumeLayout(false);
             this.statusStrip1.PerformLayout();
             this.ResumeLayout(false);

+ 5 - 0
Welling_Motor_Debug_Tool/Scan.cs

@@ -21,5 +21,10 @@ namespace Welling_Motor_Debug_Tool
         {
             this.Close();
         }
+
+        private void Scan_Load(object sender, EventArgs e)
+        {
+
+        }
     }
 }

二進制
Welling_Motor_Debug_Tool/bin/Debug/Welling_Motor_Debug_Tool.exe


二進制
Welling_Motor_Debug_Tool/bin/Debug/Welling_Motor_Debug_Tool.pdb


二進制
Welling_Motor_Debug_Tool/obj/Debug/Welling_Motor_Debug_Tool.csproj.GenerateResource.cache


二進制
Welling_Motor_Debug_Tool/obj/Debug/Welling_Motor_Debug_Tool.exe


二進制
Welling_Motor_Debug_Tool/obj/Debug/Welling_Motor_Debug_Tool.pdb