Commit 92a84c90 by 陶然

界面布局优化

parent 0142679c
...@@ -96,6 +96,7 @@ ...@@ -96,6 +96,7 @@
// //
// gbInfo // gbInfo
// //
this.gbInfo.Controls.Add(this.btnInstallDriver);
this.gbInfo.Controls.Add(this.lbCurrentPackageNode); this.gbInfo.Controls.Add(this.lbCurrentPackageNode);
this.gbInfo.Controls.Add(this.lbCurrentPackage); this.gbInfo.Controls.Add(this.lbCurrentPackage);
this.gbInfo.Controls.Add(this.lbCurrentLocation); this.gbInfo.Controls.Add(this.lbCurrentLocation);
...@@ -118,7 +119,7 @@ ...@@ -118,7 +119,7 @@
this.lbCurrentPackageNode.Font = new System.Drawing.Font("宋体", 12F); this.lbCurrentPackageNode.Font = new System.Drawing.Font("宋体", 12F);
this.lbCurrentPackageNode.Location = new System.Drawing.Point(16, 180); this.lbCurrentPackageNode.Location = new System.Drawing.Point(16, 180);
this.lbCurrentPackageNode.Name = "lbCurrentPackageNode"; this.lbCurrentPackageNode.Name = "lbCurrentPackageNode";
this.lbCurrentPackageNode.Size = new System.Drawing.Size(80, 16); this.lbCurrentPackageNode.Size = new System.Drawing.Size(79, 16);
this.lbCurrentPackageNode.TabIndex = 7; this.lbCurrentPackageNode.TabIndex = 7;
this.lbCurrentPackageNode.Text = "当前袋子:"; this.lbCurrentPackageNode.Text = "当前袋子:";
// //
...@@ -128,7 +129,7 @@ ...@@ -128,7 +129,7 @@
this.lbCurrentPackage.Font = new System.Drawing.Font("宋体", 12F); this.lbCurrentPackage.Font = new System.Drawing.Font("宋体", 12F);
this.lbCurrentPackage.Location = new System.Drawing.Point(16, 127); this.lbCurrentPackage.Location = new System.Drawing.Point(16, 127);
this.lbCurrentPackage.Name = "lbCurrentPackage"; this.lbCurrentPackage.Name = "lbCurrentPackage";
this.lbCurrentPackage.Size = new System.Drawing.Size(80, 16); this.lbCurrentPackage.Size = new System.Drawing.Size(79, 16);
this.lbCurrentPackage.TabIndex = 6; this.lbCurrentPackage.TabIndex = 6;
this.lbCurrentPackage.Text = "当前箱号:"; this.lbCurrentPackage.Text = "当前箱号:";
// //
...@@ -138,7 +139,7 @@ ...@@ -138,7 +139,7 @@
this.lbCurrentLocation.Font = new System.Drawing.Font("宋体", 12F); this.lbCurrentLocation.Font = new System.Drawing.Font("宋体", 12F);
this.lbCurrentLocation.Location = new System.Drawing.Point(16, 74); this.lbCurrentLocation.Location = new System.Drawing.Point(16, 74);
this.lbCurrentLocation.Name = "lbCurrentLocation"; this.lbCurrentLocation.Name = "lbCurrentLocation";
this.lbCurrentLocation.Size = new System.Drawing.Size(80, 16); this.lbCurrentLocation.Size = new System.Drawing.Size(79, 16);
this.lbCurrentLocation.TabIndex = 5; this.lbCurrentLocation.TabIndex = 5;
this.lbCurrentLocation.Text = "当前位置:"; this.lbCurrentLocation.Text = "当前位置:";
// //
...@@ -148,7 +149,7 @@ ...@@ -148,7 +149,7 @@
this.lbCurrentDepartment.Font = new System.Drawing.Font("宋体", 12F); this.lbCurrentDepartment.Font = new System.Drawing.Font("宋体", 12F);
this.lbCurrentDepartment.Location = new System.Drawing.Point(16, 21); this.lbCurrentDepartment.Location = new System.Drawing.Point(16, 21);
this.lbCurrentDepartment.Name = "lbCurrentDepartment"; this.lbCurrentDepartment.Name = "lbCurrentDepartment";
this.lbCurrentDepartment.Size = new System.Drawing.Size(80, 16); this.lbCurrentDepartment.Size = new System.Drawing.Size(79, 16);
this.lbCurrentDepartment.TabIndex = 4; this.lbCurrentDepartment.TabIndex = 4;
this.lbCurrentDepartment.Text = "当前部门:"; this.lbCurrentDepartment.Text = "当前部门:";
// //
...@@ -316,7 +317,6 @@ ...@@ -316,7 +317,6 @@
// //
// gbTools // gbTools
// //
this.gbTools.Controls.Add(this.btnInstallDriver);
this.gbTools.Controls.Add(this.ckbAutoCreatePackage); this.gbTools.Controls.Add(this.ckbAutoCreatePackage);
this.gbTools.Controls.Add(this.lbTips); this.gbTools.Controls.Add(this.lbTips);
this.gbTools.Controls.Add(this.lbScanSample); this.gbTools.Controls.Add(this.lbScanSample);
...@@ -571,13 +571,15 @@ ...@@ -571,13 +571,15 @@
// //
// btnInstallDriver // btnInstallDriver
// //
this.btnInstallDriver.BackColor = System.Drawing.SystemColors.Control;
this.btnInstallDriver.Dock = System.Windows.Forms.DockStyle.Bottom; this.btnInstallDriver.Dock = System.Windows.Forms.DockStyle.Bottom;
this.btnInstallDriver.Location = new System.Drawing.Point(3, 99); this.btnInstallDriver.ForeColor = System.Drawing.SystemColors.ControlText;
this.btnInstallDriver.Location = new System.Drawing.Point(3, 272);
this.btnInstallDriver.Name = "btnInstallDriver"; this.btnInstallDriver.Name = "btnInstallDriver";
this.btnInstallDriver.Size = new System.Drawing.Size(780, 23); this.btnInstallDriver.Size = new System.Drawing.Size(259, 38);
this.btnInstallDriver.TabIndex = 82; this.btnInstallDriver.TabIndex = 83;
this.btnInstallDriver.Text = "驱动安装"; this.btnInstallDriver.Text = "驱动安装";
this.btnInstallDriver.UseVisualStyleBackColor = true; this.btnInstallDriver.UseVisualStyleBackColor = false;
this.btnInstallDriver.Visible = false; this.btnInstallDriver.Visible = false;
this.btnInstallDriver.Click += new System.EventHandler(this.btnInstallDriver_Click); this.btnInstallDriver.Click += new System.EventHandler(this.btnInstallDriver_Click);
// //
...@@ -591,7 +593,7 @@ ...@@ -591,7 +593,7 @@
this.Controls.Add(this.plLeft); this.Controls.Add(this.plLeft);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Name = "FrmMain"; this.Name = "FrmMain";
this.Text = "样品入箱客户端 1.0(23.6.12 CP2101)"; this.Text = "样品入箱客户端 1.0(23.6.14 CP2101)";
this.Load += new System.EventHandler(this.FrmMain_Load); this.Load += new System.EventHandler(this.FrmMain_Load);
this.plLeft.ResumeLayout(false); this.plLeft.ResumeLayout(false);
this.gbInfo.ResumeLayout(false); this.gbInfo.ResumeLayout(false);
......
...@@ -686,6 +686,7 @@ namespace Kivii.Client.SamplePackages ...@@ -686,6 +686,7 @@ namespace Kivii.Client.SamplePackages
try try
{ {
ReaderInstance.AutoOpenComPort(); ReaderInstance.AutoOpenComPort();
btnInstallDriver.Visible = true;
} }
catch (Exception ex) catch (Exception ex)
{ {
......
...@@ -32,5 +32,5 @@ using System.Runtime.InteropServices; ...@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 //可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
//通过使用 "*",如下所示: //通过使用 "*",如下所示:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("5.4.2023.6120")] [assembly: AssemblyVersion("5.4.2023.6140")]
[assembly: AssemblyFileVersion("5.4.2023.6120")] [assembly: AssemblyFileVersion("5.4.2023.6140")]
...@@ -256,10 +256,18 @@ namespace Kivii.Client.SamplePackages ...@@ -256,10 +256,18 @@ namespace Kivii.Client.SamplePackages
if (!fileName.ToLower().Contains(".cp2101_setup.exe")) continue; if (!fileName.ToLower().Contains(".cp2101_setup.exe")) continue;
localFileName = Path.Combine(savePath, "setup.exe"); localFileName = Path.Combine(savePath, "setup.exe");
var stream = assembly.GetManifestResourceStream(fileName); var stream = assembly.GetManifestResourceStream(fileName);
try
{
using (var fileStream = new FileStream(localFileName, FileMode.Create)) using (var fileStream = new FileStream(localFileName, FileMode.Create))
{ {
stream.CopyTo(fileStream); stream.CopyTo(fileStream);
} }
}
catch (Exception ex)
{
MessageBox.Show(ex.Message, "安装错误");
return;
}
stream.Dispose(); stream.Dispose();
break; break;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment