diff --git a/WindowsFormsApp1/MES_PLC_Control.csproj b/WindowsFormsApp1/MES_PLC_Control.csproj
index a99a225..b417f2d 100644
--- a/WindowsFormsApp1/MES_PLC_Control.csproj
+++ b/WindowsFormsApp1/MES_PLC_Control.csproj
@@ -69,6 +69,12 @@
LINE_Manage.cs
+
+ Form
+
+
+ SerialPort_Manage.cs
+
Form
@@ -110,6 +116,7 @@
+
@@ -135,6 +142,9 @@
LINE_Manage.cs
+
+ SerialPort_Manage.cs
+
PLCADDRESS_Manage.cs
diff --git a/WindowsFormsApp1/MainForm.Designer.cs b/WindowsFormsApp1/MainForm.Designer.cs
index 19081c1..fd69b8e 100644
--- a/WindowsFormsApp1/MainForm.Designer.cs
+++ b/WindowsFormsApp1/MainForm.Designer.cs
@@ -45,9 +45,35 @@
this.扭力曲线配置ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.系统参数配置ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
+ this.tableLayoutPanel4 = new System.Windows.Forms.TableLayoutPanel();
+ this.gropb = new System.Windows.Forms.GroupBox();
+ this.tableLayoutPanel6 = new System.Windows.Forms.TableLayoutPanel();
+ this.Tray盘 = new System.Windows.Forms.Label();
+ this.Tray盘二维码 = new System.Windows.Forms.Label();
+ this.原料包装LOT号 = new System.Windows.Forms.GroupBox();
+ this.tableLayoutPanel5 = new System.Windows.Forms.TableLayoutPanel();
+ this.LOT号扫描 = new System.Windows.Forms.Label();
+ this.LOT号显示 = new System.Windows.Forms.Label();
+ this.LOT号 = new System.Windows.Forms.Label();
+ this.请扫描LOT号 = new System.Windows.Forms.Label();
+ this.groupBox2 = new System.Windows.Forms.GroupBox();
+ this.tableLayoutPanel7 = new System.Windows.Forms.TableLayoutPanel();
+ this.事件4时间 = new System.Windows.Forms.Label();
+ this.事件3时间 = new System.Windows.Forms.Label();
+ this.事件2时间 = new System.Windows.Forms.Label();
+ this.事件1时间 = new System.Windows.Forms.Label();
+ this.事件2 = new System.Windows.Forms.Label();
+ this.事件1 = new System.Windows.Forms.Label();
+ this.事件2结果 = new System.Windows.Forms.Label();
+ this.事件1结果 = new System.Windows.Forms.Label();
+ this.事件3结果 = new System.Windows.Forms.Label();
+ this.事件3 = new System.Windows.Forms.Label();
+ this.事件4 = new System.Windows.Forms.Label();
+ this.事件4结果 = new System.Windows.Forms.Label();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel();
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
+ this.机台状态 = new System.Windows.Forms.Label();
this.PLC通讯时间 = new System.Windows.Forms.Label();
this.MES通讯时间 = new System.Windows.Forms.Label();
this.PLC链接状态 = new System.Windows.Forms.Label();
@@ -66,40 +92,9 @@
this.底部注释3 = new System.Windows.Forms.Label();
this.底部注释4 = new System.Windows.Forms.Label();
this.底部注释5 = new System.Windows.Forms.Label();
- this.tableLayoutPanel4 = new System.Windows.Forms.TableLayoutPanel();
- this.gropb = new System.Windows.Forms.GroupBox();
- this.tableLayoutPanel6 = new System.Windows.Forms.TableLayoutPanel();
- this.Tray盘 = new System.Windows.Forms.Label();
- this.Tray盘二维码 = new System.Windows.Forms.Label();
- this.原料包装LOT号 = new System.Windows.Forms.GroupBox();
- this.tableLayoutPanel5 = new System.Windows.Forms.TableLayoutPanel();
- this.LOT号显示 = new System.Windows.Forms.Label();
- this.LOT号 = new System.Windows.Forms.Label();
- this.请扫描LOT号 = new System.Windows.Forms.Label();
- this.groupBox2 = new System.Windows.Forms.GroupBox();
- this.tableLayoutPanel7 = new System.Windows.Forms.TableLayoutPanel();
- this.事件4 = new System.Windows.Forms.Label();
- this.事件3 = new System.Windows.Forms.Label();
- this.事件4结果 = new System.Windows.Forms.Label();
- this.事件3结果 = new System.Windows.Forms.Label();
- this.事件2 = new System.Windows.Forms.Label();
- this.事件1 = new System.Windows.Forms.Label();
- this.事件2结果 = new System.Windows.Forms.Label();
- this.事件1结果 = new System.Windows.Forms.Label();
this.timer1 = new System.Windows.Forms.Timer(this.components);
- this.LOT号扫描 = new System.Windows.Forms.Label();
- this.事件1时间 = new System.Windows.Forms.Label();
- this.事件2时间 = new System.Windows.Forms.Label();
- this.事件3时间 = new System.Windows.Forms.Label();
- this.事件4时间 = new System.Windows.Forms.Label();
- this.机台状态 = new System.Windows.Forms.Label();
this.menuStrip1.SuspendLayout();
this.tableLayoutPanel1.SuspendLayout();
- this.groupBox1.SuspendLayout();
- this.tableLayoutPanel3.SuspendLayout();
- this.tableLayoutPanel2.SuspendLayout();
- this.groupBox3.SuspendLayout();
- this.tableLayoutPanel8.SuspendLayout();
this.tableLayoutPanel4.SuspendLayout();
this.gropb.SuspendLayout();
this.tableLayoutPanel6.SuspendLayout();
@@ -107,6 +102,11 @@
this.tableLayoutPanel5.SuspendLayout();
this.groupBox2.SuspendLayout();
this.tableLayoutPanel7.SuspendLayout();
+ this.groupBox1.SuspendLayout();
+ this.tableLayoutPanel3.SuspendLayout();
+ this.tableLayoutPanel2.SuspendLayout();
+ this.groupBox3.SuspendLayout();
+ this.tableLayoutPanel8.SuspendLayout();
this.SuspendLayout();
//
// menuStrip1
@@ -142,21 +142,21 @@
// 修改密码ToolStripMenuItem
//
this.修改密码ToolStripMenuItem.Name = "修改密码ToolStripMenuItem";
- this.修改密码ToolStripMenuItem.Size = new System.Drawing.Size(315, 44);
+ this.修改密码ToolStripMenuItem.Size = new System.Drawing.Size(247, 44);
this.修改密码ToolStripMenuItem.Text = "修改密码";
this.修改密码ToolStripMenuItem.Click += new System.EventHandler(this.修改密码ToolStripMenuItem_Click);
//
// 切换用户ToolStripMenuItem
//
this.切换用户ToolStripMenuItem.Name = "切换用户ToolStripMenuItem";
- this.切换用户ToolStripMenuItem.Size = new System.Drawing.Size(315, 44);
+ this.切换用户ToolStripMenuItem.Size = new System.Drawing.Size(247, 44);
this.切换用户ToolStripMenuItem.Text = "切换用户";
this.切换用户ToolStripMenuItem.Click += new System.EventHandler(this.切换用户ToolStripMenuItem_Click);
//
// 用户管理ToolStripMenuItem1
//
this.用户管理ToolStripMenuItem1.Name = "用户管理ToolStripMenuItem1";
- this.用户管理ToolStripMenuItem1.Size = new System.Drawing.Size(315, 44);
+ this.用户管理ToolStripMenuItem1.Size = new System.Drawing.Size(247, 44);
this.用户管理ToolStripMenuItem1.Text = "用户管理";
this.用户管理ToolStripMenuItem1.Click += new System.EventHandler(this.用户管理ToolStripMenuItem1_Click);
//
@@ -179,14 +179,14 @@
// pLC通讯设置ToolStripMenuItem
//
this.pLC通讯设置ToolStripMenuItem.Name = "pLC通讯设置ToolStripMenuItem";
- this.pLC通讯设置ToolStripMenuItem.Size = new System.Drawing.Size(315, 44);
+ this.pLC通讯设置ToolStripMenuItem.Size = new System.Drawing.Size(297, 44);
this.pLC通讯设置ToolStripMenuItem.Text = "PLC通讯设置";
this.pLC通讯设置ToolStripMenuItem.Click += new System.EventHandler(this.pLC通讯设置ToolStripMenuItem_Click);
//
// pLC地址设置ToolStripMenuItem
//
this.pLC地址设置ToolStripMenuItem.Name = "pLC地址设置ToolStripMenuItem";
- this.pLC地址设置ToolStripMenuItem.Size = new System.Drawing.Size(315, 44);
+ this.pLC地址设置ToolStripMenuItem.Size = new System.Drawing.Size(297, 44);
this.pLC地址设置ToolStripMenuItem.Text = "PLC地址设置";
this.pLC地址设置ToolStripMenuItem.Click += new System.EventHandler(this.pLC地址设置ToolStripMenuItem_Click);
//
@@ -218,6 +218,7 @@
this.扫码枪配置ToolStripMenuItem1.Name = "扫码枪配置ToolStripMenuItem1";
this.扫码枪配置ToolStripMenuItem1.Size = new System.Drawing.Size(315, 44);
this.扫码枪配置ToolStripMenuItem1.Text = "扫码枪配置";
+ this.扫码枪配置ToolStripMenuItem1.Click += new System.EventHandler(this.扫码枪配置ToolStripMenuItem1_Click);
//
// 扭力曲线配置ToolStripMenuItem
//
@@ -251,6 +252,328 @@
this.tableLayoutPanel1.Size = new System.Drawing.Size(1613, 935);
this.tableLayoutPanel1.TabIndex = 6;
//
+ // tableLayoutPanel4
+ //
+ this.tableLayoutPanel4.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
+ | System.Windows.Forms.AnchorStyles.Left)
+ | System.Windows.Forms.AnchorStyles.Right)));
+ this.tableLayoutPanel4.ColumnCount = 2;
+ this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 76.54172F));
+ this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 23.45828F));
+ this.tableLayoutPanel4.Controls.Add(this.gropb, 0, 1);
+ this.tableLayoutPanel4.Controls.Add(this.原料包装LOT号, 0, 0);
+ this.tableLayoutPanel4.Controls.Add(this.groupBox2, 1, 0);
+ this.tableLayoutPanel4.Location = new System.Drawing.Point(3, 131);
+ this.tableLayoutPanel4.Name = "tableLayoutPanel4";
+ this.tableLayoutPanel4.RowCount = 2;
+ this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 60.04619F));
+ this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 39.95381F));
+ this.tableLayoutPanel4.Size = new System.Drawing.Size(1607, 455);
+ this.tableLayoutPanel4.TabIndex = 8;
+ //
+ // gropb
+ //
+ this.gropb.Controls.Add(this.tableLayoutPanel6);
+ this.gropb.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.gropb.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.gropb.Location = new System.Drawing.Point(3, 276);
+ this.gropb.Name = "gropb";
+ this.gropb.Size = new System.Drawing.Size(1224, 176);
+ this.gropb.TabIndex = 1;
+ this.gropb.TabStop = false;
+ this.gropb.Text = "Tray盘二维码";
+ //
+ // tableLayoutPanel6
+ //
+ this.tableLayoutPanel6.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Single;
+ this.tableLayoutPanel6.ColumnCount = 2;
+ this.tableLayoutPanel6.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel6.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 80F));
+ this.tableLayoutPanel6.Controls.Add(this.Tray盘, 0, 0);
+ this.tableLayoutPanel6.Controls.Add(this.Tray盘二维码, 1, 0);
+ this.tableLayoutPanel6.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel6.Location = new System.Drawing.Point(3, 35);
+ this.tableLayoutPanel6.Name = "tableLayoutPanel6";
+ this.tableLayoutPanel6.RowCount = 1;
+ this.tableLayoutPanel6.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
+ this.tableLayoutPanel6.Size = new System.Drawing.Size(1218, 138);
+ this.tableLayoutPanel6.TabIndex = 1;
+ //
+ // Tray盘
+ //
+ this.Tray盘.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.Tray盘.AutoSize = true;
+ this.Tray盘.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.Tray盘.Location = new System.Drawing.Point(8, 27);
+ this.Tray盘.Name = "Tray盘";
+ this.Tray盘.Size = new System.Drawing.Size(228, 84);
+ this.Tray盘.TabIndex = 3;
+ this.Tray盘.Text = "Tray盘二维码:";
+ //
+ // Tray盘二维码
+ //
+ this.Tray盘二维码.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.Tray盘二维码.AutoSize = true;
+ this.Tray盘二维码.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.Tray盘二维码.Location = new System.Drawing.Point(397, 7);
+ this.Tray盘二维码.Name = "Tray盘二维码";
+ this.Tray盘二维码.Size = new System.Drawing.Size(667, 124);
+ this.Tray盘二维码.TabIndex = 2;
+ this.Tray盘二维码.Text = "Tray盘二维码:92139129312381928938";
+ //
+ // 原料包装LOT号
+ //
+ this.原料包装LOT号.Controls.Add(this.tableLayoutPanel5);
+ this.原料包装LOT号.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.原料包装LOT号.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.原料包装LOT号.Location = new System.Drawing.Point(3, 3);
+ this.原料包装LOT号.Name = "原料包装LOT号";
+ this.原料包装LOT号.Size = new System.Drawing.Size(1224, 267);
+ this.原料包装LOT号.TabIndex = 0;
+ this.原料包装LOT号.TabStop = false;
+ this.原料包装LOT号.Text = "原料包装LOT号";
+ //
+ // tableLayoutPanel5
+ //
+ this.tableLayoutPanel5.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
+ this.tableLayoutPanel5.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Single;
+ this.tableLayoutPanel5.ColumnCount = 2;
+ this.tableLayoutPanel5.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel5.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 80F));
+ this.tableLayoutPanel5.Controls.Add(this.LOT号扫描, 0, 0);
+ this.tableLayoutPanel5.Controls.Add(this.LOT号显示, 0, 1);
+ this.tableLayoutPanel5.Controls.Add(this.LOT号, 1, 1);
+ this.tableLayoutPanel5.Controls.Add(this.请扫描LOT号, 1, 0);
+ this.tableLayoutPanel5.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel5.Location = new System.Drawing.Point(3, 35);
+ this.tableLayoutPanel5.Name = "tableLayoutPanel5";
+ this.tableLayoutPanel5.RowCount = 2;
+ this.tableLayoutPanel5.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
+ this.tableLayoutPanel5.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
+ this.tableLayoutPanel5.Size = new System.Drawing.Size(1218, 229);
+ this.tableLayoutPanel5.TabIndex = 0;
+ //
+ // LOT号扫描
+ //
+ this.LOT号扫描.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.LOT号扫描.AutoSize = true;
+ this.LOT号扫描.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.LOT号扫描.Location = new System.Drawing.Point(40, 15);
+ this.LOT号扫描.Name = "LOT号扫描";
+ this.LOT号扫描.Size = new System.Drawing.Size(165, 84);
+ this.LOT号扫描.TabIndex = 3;
+ this.LOT号扫描.Text = "LOT号扫描:";
+ //
+ // LOT号显示
+ //
+ this.LOT号显示.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.LOT号显示.AutoSize = true;
+ this.LOT号显示.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.LOT号显示.Location = new System.Drawing.Point(40, 129);
+ this.LOT号显示.Name = "LOT号显示";
+ this.LOT号显示.Size = new System.Drawing.Size(165, 84);
+ this.LOT号显示.TabIndex = 2;
+ this.LOT号显示.Text = "LOT号显示:";
+ //
+ // LOT号
+ //
+ this.LOT号.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.LOT号.AutoSize = true;
+ this.LOT号.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.LOT号.Location = new System.Drawing.Point(270, 140);
+ this.LOT号.Name = "LOT号";
+ this.LOT号.Size = new System.Drawing.Size(921, 62);
+ this.LOT号.TabIndex = 0;
+ this.LOT号.Text = "LOT号:231321919199191919191";
+ //
+ // 请扫描LOT号
+ //
+ this.请扫描LOT号.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.请扫描LOT号.AutoSize = true;
+ this.请扫描LOT号.Font = new System.Drawing.Font("宋体", 24F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.请扫描LOT号.ForeColor = System.Drawing.Color.Red;
+ this.请扫描LOT号.Location = new System.Drawing.Point(476, 29);
+ this.请扫描LOT号.Name = "请扫描LOT号";
+ this.请扫描LOT号.Size = new System.Drawing.Size(510, 56);
+ this.请扫描LOT号.TabIndex = 1;
+ this.请扫描LOT号.Text = "请员工扫描LOT号:";
+ //
+ // groupBox2
+ //
+ this.groupBox2.Controls.Add(this.tableLayoutPanel7);
+ this.groupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.groupBox2.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.groupBox2.Location = new System.Drawing.Point(1233, 3);
+ this.groupBox2.Name = "groupBox2";
+ this.tableLayoutPanel4.SetRowSpan(this.groupBox2, 2);
+ this.groupBox2.Size = new System.Drawing.Size(371, 449);
+ this.groupBox2.TabIndex = 2;
+ this.groupBox2.TabStop = false;
+ this.groupBox2.Text = "MES事件结果";
+ //
+ // tableLayoutPanel7
+ //
+ this.tableLayoutPanel7.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Single;
+ this.tableLayoutPanel7.ColumnCount = 2;
+ this.tableLayoutPanel7.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
+ this.tableLayoutPanel7.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
+ this.tableLayoutPanel7.Controls.Add(this.事件4时间, 1, 5);
+ this.tableLayoutPanel7.Controls.Add(this.事件3时间, 0, 5);
+ this.tableLayoutPanel7.Controls.Add(this.事件2时间, 1, 2);
+ this.tableLayoutPanel7.Controls.Add(this.事件1时间, 0, 2);
+ this.tableLayoutPanel7.Controls.Add(this.事件2, 1, 1);
+ this.tableLayoutPanel7.Controls.Add(this.事件1, 0, 1);
+ this.tableLayoutPanel7.Controls.Add(this.事件2结果, 1, 0);
+ this.tableLayoutPanel7.Controls.Add(this.事件1结果, 0, 0);
+ this.tableLayoutPanel7.Controls.Add(this.事件3结果, 0, 3);
+ this.tableLayoutPanel7.Controls.Add(this.事件3, 0, 4);
+ this.tableLayoutPanel7.Controls.Add(this.事件4, 1, 4);
+ this.tableLayoutPanel7.Controls.Add(this.事件4结果, 1, 3);
+ this.tableLayoutPanel7.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel7.Location = new System.Drawing.Point(3, 35);
+ this.tableLayoutPanel7.Name = "tableLayoutPanel7";
+ this.tableLayoutPanel7.RowCount = 6;
+ this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 30F));
+ this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
+ this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
+ this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 30F));
+ this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
+ this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
+ this.tableLayoutPanel7.Size = new System.Drawing.Size(365, 411);
+ this.tableLayoutPanel7.TabIndex = 0;
+ //
+ // 事件4时间
+ //
+ this.事件4时间.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件4时间.AutoSize = true;
+ this.事件4时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件4时间.Location = new System.Drawing.Point(189, 372);
+ this.事件4时间.Name = "事件4时间";
+ this.事件4时间.Size = new System.Drawing.Size(168, 34);
+ this.事件4时间.TabIndex = 11;
+ this.事件4时间.Text = "事件4时间";
+ //
+ // 事件3时间
+ //
+ this.事件3时间.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件3时间.AutoSize = true;
+ this.事件3时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件3时间.Location = new System.Drawing.Point(7, 372);
+ this.事件3时间.Name = "事件3时间";
+ this.事件3时间.Size = new System.Drawing.Size(168, 34);
+ this.事件3时间.TabIndex = 10;
+ this.事件3时间.Text = "事件3时间";
+ //
+ // 事件2时间
+ //
+ this.事件2时间.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件2时间.AutoSize = true;
+ this.事件2时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件2时间.Location = new System.Drawing.Point(189, 167);
+ this.事件2时间.Name = "事件2时间";
+ this.事件2时间.Size = new System.Drawing.Size(168, 34);
+ this.事件2时间.TabIndex = 9;
+ this.事件2时间.Text = "事件2时间";
+ //
+ // 事件1时间
+ //
+ this.事件1时间.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件1时间.AutoSize = true;
+ this.事件1时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件1时间.Location = new System.Drawing.Point(7, 167);
+ this.事件1时间.Name = "事件1时间";
+ this.事件1时间.Size = new System.Drawing.Size(168, 34);
+ this.事件1时间.TabIndex = 8;
+ this.事件1时间.Text = "事件1时间";
+ //
+ // 事件2
+ //
+ this.事件2.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件2.AutoSize = true;
+ this.事件2.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件2.Location = new System.Drawing.Point(223, 126);
+ this.事件2.Name = "事件2";
+ this.事件2.Size = new System.Drawing.Size(100, 34);
+ this.事件2.TabIndex = 3;
+ this.事件2.Text = "事件2";
+ //
+ // 事件1
+ //
+ this.事件1.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件1.AutoSize = true;
+ this.事件1.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件1.Location = new System.Drawing.Point(41, 126);
+ this.事件1.Name = "事件1";
+ this.事件1.Size = new System.Drawing.Size(100, 34);
+ this.事件1.TabIndex = 2;
+ this.事件1.Text = "事件1";
+ //
+ // 事件2结果
+ //
+ this.事件2结果.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件2结果.AutoSize = true;
+ this.事件2结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件2结果.Location = new System.Drawing.Point(228, 30);
+ this.事件2结果.Name = "事件2结果";
+ this.事件2结果.Size = new System.Drawing.Size(91, 62);
+ this.事件2结果.TabIndex = 1;
+ this.事件2结果.Text = "OK";
+ //
+ // 事件1结果
+ //
+ this.事件1结果.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件1结果.AutoSize = true;
+ this.事件1结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件1结果.Location = new System.Drawing.Point(46, 30);
+ this.事件1结果.Name = "事件1结果";
+ this.事件1结果.Size = new System.Drawing.Size(91, 62);
+ this.事件1结果.TabIndex = 0;
+ this.事件1结果.Text = "OK";
+ //
+ // 事件3结果
+ //
+ this.事件3结果.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件3结果.AutoSize = true;
+ this.事件3结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件3结果.Location = new System.Drawing.Point(46, 234);
+ this.事件3结果.Name = "事件3结果";
+ this.事件3结果.Size = new System.Drawing.Size(91, 62);
+ this.事件3结果.TabIndex = 4;
+ this.事件3结果.Text = "OK";
+ //
+ // 事件3
+ //
+ this.事件3.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件3.AutoSize = true;
+ this.事件3.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件3.Location = new System.Drawing.Point(41, 330);
+ this.事件3.Name = "事件3";
+ this.事件3.Size = new System.Drawing.Size(100, 34);
+ this.事件3.TabIndex = 6;
+ this.事件3.Text = "事件3";
+ //
+ // 事件4
+ //
+ this.事件4.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件4.AutoSize = true;
+ this.事件4.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件4.Location = new System.Drawing.Point(223, 330);
+ this.事件4.Name = "事件4";
+ this.事件4.Size = new System.Drawing.Size(100, 34);
+ this.事件4.TabIndex = 7;
+ this.事件4.Text = "事件4";
+ //
+ // 事件4结果
+ //
+ this.事件4结果.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.事件4结果.AutoSize = true;
+ this.事件4结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.事件4结果.Location = new System.Drawing.Point(228, 234);
+ this.事件4结果.Name = "事件4结果";
+ this.事件4结果.Size = new System.Drawing.Size(91, 62);
+ this.事件4结果.TabIndex = 5;
+ this.事件4结果.Text = "OK";
+ //
// groupBox1
//
this.groupBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
@@ -325,6 +648,19 @@
this.tableLayoutPanel2.Size = new System.Drawing.Size(1411, 58);
this.tableLayoutPanel2.TabIndex = 3;
//
+ // 机台状态
+ //
+ this.机台状态.AutoSize = true;
+ this.机台状态.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.机台状态.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.机台状态.Location = new System.Drawing.Point(852, 29);
+ this.机台状态.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
+ this.机台状态.Name = "机台状态";
+ this.机台状态.Size = new System.Drawing.Size(271, 28);
+ this.机台状态.TabIndex = 17;
+ this.机台状态.Text = "机台状态:None";
+ this.机台状态.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+ //
// PLC通讯时间
//
this.PLC通讯时间.AutoSize = true;
@@ -556,347 +892,12 @@
this.底部注释5.TabIndex = 4;
this.底部注释5.Text = "底部注释5";
//
- // tableLayoutPanel4
- //
- this.tableLayoutPanel4.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
- this.tableLayoutPanel4.ColumnCount = 2;
- this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 76.54172F));
- this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 23.45828F));
- this.tableLayoutPanel4.Controls.Add(this.gropb, 0, 1);
- this.tableLayoutPanel4.Controls.Add(this.原料包装LOT号, 0, 0);
- this.tableLayoutPanel4.Controls.Add(this.groupBox2, 1, 0);
- this.tableLayoutPanel4.Location = new System.Drawing.Point(3, 131);
- this.tableLayoutPanel4.Name = "tableLayoutPanel4";
- this.tableLayoutPanel4.RowCount = 2;
- this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 60.04619F));
- this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 39.95381F));
- this.tableLayoutPanel4.Size = new System.Drawing.Size(1607, 455);
- this.tableLayoutPanel4.TabIndex = 8;
- //
- // gropb
- //
- this.gropb.Controls.Add(this.tableLayoutPanel6);
- this.gropb.Dock = System.Windows.Forms.DockStyle.Fill;
- this.gropb.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.gropb.Location = new System.Drawing.Point(3, 276);
- this.gropb.Name = "gropb";
- this.gropb.Size = new System.Drawing.Size(1224, 176);
- this.gropb.TabIndex = 1;
- this.gropb.TabStop = false;
- this.gropb.Text = "Tray盘二维码";
- //
- // tableLayoutPanel6
- //
- this.tableLayoutPanel6.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Single;
- this.tableLayoutPanel6.ColumnCount = 2;
- this.tableLayoutPanel6.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
- this.tableLayoutPanel6.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 80F));
- this.tableLayoutPanel6.Controls.Add(this.Tray盘, 0, 0);
- this.tableLayoutPanel6.Controls.Add(this.Tray盘二维码, 1, 0);
- this.tableLayoutPanel6.Dock = System.Windows.Forms.DockStyle.Fill;
- this.tableLayoutPanel6.Location = new System.Drawing.Point(3, 35);
- this.tableLayoutPanel6.Name = "tableLayoutPanel6";
- this.tableLayoutPanel6.RowCount = 1;
- this.tableLayoutPanel6.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
- this.tableLayoutPanel6.Size = new System.Drawing.Size(1218, 138);
- this.tableLayoutPanel6.TabIndex = 1;
- //
- // Tray盘
- //
- this.Tray盘.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.Tray盘.AutoSize = true;
- this.Tray盘.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.Tray盘.Location = new System.Drawing.Point(8, 27);
- this.Tray盘.Name = "Tray盘";
- this.Tray盘.Size = new System.Drawing.Size(228, 84);
- this.Tray盘.TabIndex = 3;
- this.Tray盘.Text = "Tray盘二维码:";
- //
- // Tray盘二维码
- //
- this.Tray盘二维码.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.Tray盘二维码.AutoSize = true;
- this.Tray盘二维码.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.Tray盘二维码.Location = new System.Drawing.Point(397, 8);
- this.Tray盘二维码.Name = "Tray盘二维码";
- this.Tray盘二维码.Size = new System.Drawing.Size(667, 122);
- this.Tray盘二维码.TabIndex = 2;
- this.Tray盘二维码.Text = "Tray盘二维码:92139129312381928938";
- //
- // 原料包装LOT号
- //
- this.原料包装LOT号.Controls.Add(this.tableLayoutPanel5);
- this.原料包装LOT号.Dock = System.Windows.Forms.DockStyle.Fill;
- this.原料包装LOT号.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.原料包装LOT号.Location = new System.Drawing.Point(3, 3);
- this.原料包装LOT号.Name = "原料包装LOT号";
- this.原料包装LOT号.Size = new System.Drawing.Size(1224, 267);
- this.原料包装LOT号.TabIndex = 0;
- this.原料包装LOT号.TabStop = false;
- this.原料包装LOT号.Text = "原料包装LOT号";
- //
- // tableLayoutPanel5
- //
- this.tableLayoutPanel5.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
- this.tableLayoutPanel5.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Single;
- this.tableLayoutPanel5.ColumnCount = 2;
- this.tableLayoutPanel5.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
- this.tableLayoutPanel5.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 80F));
- this.tableLayoutPanel5.Controls.Add(this.LOT号扫描, 0, 0);
- this.tableLayoutPanel5.Controls.Add(this.LOT号显示, 0, 1);
- this.tableLayoutPanel5.Controls.Add(this.LOT号, 1, 1);
- this.tableLayoutPanel5.Controls.Add(this.请扫描LOT号, 1, 0);
- this.tableLayoutPanel5.Dock = System.Windows.Forms.DockStyle.Fill;
- this.tableLayoutPanel5.Location = new System.Drawing.Point(3, 35);
- this.tableLayoutPanel5.Name = "tableLayoutPanel5";
- this.tableLayoutPanel5.RowCount = 2;
- this.tableLayoutPanel5.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
- this.tableLayoutPanel5.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
- this.tableLayoutPanel5.Size = new System.Drawing.Size(1218, 229);
- this.tableLayoutPanel5.TabIndex = 0;
- //
- // LOT号显示
- //
- this.LOT号显示.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.LOT号显示.AutoSize = true;
- this.LOT号显示.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.LOT号显示.Location = new System.Drawing.Point(40, 129);
- this.LOT号显示.Name = "LOT号显示";
- this.LOT号显示.Size = new System.Drawing.Size(165, 84);
- this.LOT号显示.TabIndex = 2;
- this.LOT号显示.Text = "LOT号显示:";
- //
- // LOT号
- //
- this.LOT号.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.LOT号.AutoSize = true;
- this.LOT号.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.LOT号.Location = new System.Drawing.Point(271, 141);
- this.LOT号.Name = "LOT号";
- this.LOT号.Size = new System.Drawing.Size(919, 61);
- this.LOT号.TabIndex = 0;
- this.LOT号.Text = "LOT号:231321919199191919191";
- //
- // 请扫描LOT号
- //
- this.请扫描LOT号.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.请扫描LOT号.AutoSize = true;
- this.请扫描LOT号.Font = new System.Drawing.Font("宋体", 24F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.请扫描LOT号.ForeColor = System.Drawing.Color.Red;
- this.请扫描LOT号.Location = new System.Drawing.Point(476, 29);
- this.请扫描LOT号.Name = "请扫描LOT号";
- this.请扫描LOT号.Size = new System.Drawing.Size(510, 56);
- this.请扫描LOT号.TabIndex = 1;
- this.请扫描LOT号.Text = "请员工扫描LOT号:";
- //
- // groupBox2
- //
- this.groupBox2.Controls.Add(this.tableLayoutPanel7);
- this.groupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
- this.groupBox2.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.groupBox2.Location = new System.Drawing.Point(1233, 3);
- this.groupBox2.Name = "groupBox2";
- this.tableLayoutPanel4.SetRowSpan(this.groupBox2, 2);
- this.groupBox2.Size = new System.Drawing.Size(371, 449);
- this.groupBox2.TabIndex = 2;
- this.groupBox2.TabStop = false;
- this.groupBox2.Text = "MES事件结果";
- //
- // tableLayoutPanel7
- //
- this.tableLayoutPanel7.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.Single;
- this.tableLayoutPanel7.ColumnCount = 2;
- this.tableLayoutPanel7.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
- this.tableLayoutPanel7.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
- this.tableLayoutPanel7.Controls.Add(this.事件4时间, 1, 5);
- this.tableLayoutPanel7.Controls.Add(this.事件3时间, 0, 5);
- this.tableLayoutPanel7.Controls.Add(this.事件2时间, 1, 2);
- this.tableLayoutPanel7.Controls.Add(this.事件1时间, 0, 2);
- this.tableLayoutPanel7.Controls.Add(this.事件2, 1, 1);
- this.tableLayoutPanel7.Controls.Add(this.事件1, 0, 1);
- this.tableLayoutPanel7.Controls.Add(this.事件2结果, 1, 0);
- this.tableLayoutPanel7.Controls.Add(this.事件1结果, 0, 0);
- this.tableLayoutPanel7.Controls.Add(this.事件3结果, 0, 3);
- this.tableLayoutPanel7.Controls.Add(this.事件3, 0, 4);
- this.tableLayoutPanel7.Controls.Add(this.事件4, 1, 4);
- this.tableLayoutPanel7.Controls.Add(this.事件4结果, 1, 3);
- this.tableLayoutPanel7.Dock = System.Windows.Forms.DockStyle.Fill;
- this.tableLayoutPanel7.Location = new System.Drawing.Point(3, 35);
- this.tableLayoutPanel7.Name = "tableLayoutPanel7";
- this.tableLayoutPanel7.RowCount = 6;
- this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 30F));
- this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
- this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
- this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 30F));
- this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
- this.tableLayoutPanel7.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10F));
- this.tableLayoutPanel7.Size = new System.Drawing.Size(365, 411);
- this.tableLayoutPanel7.TabIndex = 0;
- //
- // 事件4
- //
- this.事件4.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件4.AutoSize = true;
- this.事件4.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件4.Location = new System.Drawing.Point(224, 330);
- this.事件4.Name = "事件4";
- this.事件4.Size = new System.Drawing.Size(98, 33);
- this.事件4.TabIndex = 7;
- this.事件4.Text = "事件4";
- //
- // 事件3
- //
- this.事件3.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件3.AutoSize = true;
- this.事件3.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件3.Location = new System.Drawing.Point(42, 330);
- this.事件3.Name = "事件3";
- this.事件3.Size = new System.Drawing.Size(98, 33);
- this.事件3.TabIndex = 6;
- this.事件3.Text = "事件3";
- //
- // 事件4结果
- //
- this.事件4结果.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件4结果.AutoSize = true;
- this.事件4结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件4结果.Location = new System.Drawing.Point(228, 234);
- this.事件4结果.Name = "事件4结果";
- this.事件4结果.Size = new System.Drawing.Size(91, 62);
- this.事件4结果.TabIndex = 5;
- this.事件4结果.Text = "OK";
- //
- // 事件3结果
- //
- this.事件3结果.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件3结果.AutoSize = true;
- this.事件3结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件3结果.Location = new System.Drawing.Point(46, 234);
- this.事件3结果.Name = "事件3结果";
- this.事件3结果.Size = new System.Drawing.Size(91, 62);
- this.事件3结果.TabIndex = 4;
- this.事件3结果.Text = "OK";
- //
- // 事件2
- //
- this.事件2.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件2.AutoSize = true;
- this.事件2.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件2.Location = new System.Drawing.Point(224, 126);
- this.事件2.Name = "事件2";
- this.事件2.Size = new System.Drawing.Size(98, 33);
- this.事件2.TabIndex = 3;
- this.事件2.Text = "事件2";
- //
- // 事件1
- //
- this.事件1.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件1.AutoSize = true;
- this.事件1.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件1.Location = new System.Drawing.Point(42, 126);
- this.事件1.Name = "事件1";
- this.事件1.Size = new System.Drawing.Size(98, 33);
- this.事件1.TabIndex = 2;
- this.事件1.Text = "事件1";
- //
- // 事件2结果
- //
- this.事件2结果.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件2结果.AutoSize = true;
- this.事件2结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件2结果.Location = new System.Drawing.Point(228, 30);
- this.事件2结果.Name = "事件2结果";
- this.事件2结果.Size = new System.Drawing.Size(91, 62);
- this.事件2结果.TabIndex = 1;
- this.事件2结果.Text = "OK";
- //
- // 事件1结果
- //
- this.事件1结果.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件1结果.AutoSize = true;
- this.事件1结果.Font = new System.Drawing.Font("宋体", 26.14286F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件1结果.Location = new System.Drawing.Point(46, 30);
- this.事件1结果.Name = "事件1结果";
- this.事件1结果.Size = new System.Drawing.Size(91, 62);
- this.事件1结果.TabIndex = 0;
- this.事件1结果.Text = "OK";
- //
// timer1
//
this.timer1.Enabled = true;
this.timer1.Interval = 1000;
this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
//
- // LOT号扫描
- //
- this.LOT号扫描.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.LOT号扫描.AutoSize = true;
- this.LOT号扫描.Font = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.LOT号扫描.Location = new System.Drawing.Point(40, 15);
- this.LOT号扫描.Name = "LOT号扫描";
- this.LOT号扫描.Size = new System.Drawing.Size(165, 84);
- this.LOT号扫描.TabIndex = 3;
- this.LOT号扫描.Text = "LOT号扫描:";
- //
- // 事件1时间
- //
- this.事件1时间.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件1时间.AutoSize = true;
- this.事件1时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件1时间.Location = new System.Drawing.Point(9, 167);
- this.事件1时间.Name = "事件1时间";
- this.事件1时间.Size = new System.Drawing.Size(164, 33);
- this.事件1时间.TabIndex = 8;
- this.事件1时间.Text = "事件1时间";
- //
- // 事件2时间
- //
- this.事件2时间.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件2时间.AutoSize = true;
- this.事件2时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件2时间.Location = new System.Drawing.Point(191, 167);
- this.事件2时间.Name = "事件2时间";
- this.事件2时间.Size = new System.Drawing.Size(164, 33);
- this.事件2时间.TabIndex = 9;
- this.事件2时间.Text = "事件2时间";
- //
- // 事件3时间
- //
- this.事件3时间.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件3时间.AutoSize = true;
- this.事件3时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件3时间.Location = new System.Drawing.Point(9, 372);
- this.事件3时间.Name = "事件3时间";
- this.事件3时间.Size = new System.Drawing.Size(164, 33);
- this.事件3时间.TabIndex = 10;
- this.事件3时间.Text = "事件3时间";
- //
- // 事件4时间
- //
- this.事件4时间.Anchor = System.Windows.Forms.AnchorStyles.None;
- this.事件4时间.AutoSize = true;
- this.事件4时间.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.事件4时间.Location = new System.Drawing.Point(191, 372);
- this.事件4时间.Name = "事件4时间";
- this.事件4时间.Size = new System.Drawing.Size(164, 33);
- this.事件4时间.TabIndex = 11;
- this.事件4时间.Text = "事件4时间";
- //
- // 机台状态
- //
- this.机台状态.AutoSize = true;
- this.机台状态.Dock = System.Windows.Forms.DockStyle.Fill;
- this.机台状态.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.机台状态.Location = new System.Drawing.Point(852, 29);
- this.机台状态.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
- this.机台状态.Name = "机台状态";
- this.机台状态.Size = new System.Drawing.Size(271, 28);
- this.机台状态.TabIndex = 17;
- this.机台状态.Text = "机台状态:None";
- this.机台状态.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
- //
// MainForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
@@ -914,13 +915,6 @@
this.menuStrip1.ResumeLayout(false);
this.menuStrip1.PerformLayout();
this.tableLayoutPanel1.ResumeLayout(false);
- this.groupBox1.ResumeLayout(false);
- this.tableLayoutPanel3.ResumeLayout(false);
- this.tableLayoutPanel2.ResumeLayout(false);
- this.tableLayoutPanel2.PerformLayout();
- this.groupBox3.ResumeLayout(false);
- this.tableLayoutPanel8.ResumeLayout(false);
- this.tableLayoutPanel8.PerformLayout();
this.tableLayoutPanel4.ResumeLayout(false);
this.gropb.ResumeLayout(false);
this.tableLayoutPanel6.ResumeLayout(false);
@@ -931,6 +925,13 @@
this.groupBox2.ResumeLayout(false);
this.tableLayoutPanel7.ResumeLayout(false);
this.tableLayoutPanel7.PerformLayout();
+ this.groupBox1.ResumeLayout(false);
+ this.tableLayoutPanel3.ResumeLayout(false);
+ this.tableLayoutPanel2.ResumeLayout(false);
+ this.tableLayoutPanel2.PerformLayout();
+ this.groupBox3.ResumeLayout(false);
+ this.tableLayoutPanel8.ResumeLayout(false);
+ this.tableLayoutPanel8.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
diff --git a/WindowsFormsApp1/MainForm.cs b/WindowsFormsApp1/MainForm.cs
index 2c05e3b..fddd083 100644
--- a/WindowsFormsApp1/MainForm.cs
+++ b/WindowsFormsApp1/MainForm.cs
@@ -3,6 +3,7 @@ using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
+using System.IO.Ports;
using System.Linq;
using System.Reflection;
using System.Reflection.Emit;
@@ -17,6 +18,7 @@ using HslCommunication.LogNet;
using WindowsFormsApp1.db;
using WindowsFormsApp1.form;
using WindowsFormsApp1.mod;
+using WindowsFormsApp1.mod.database;
using WindowsFormsApp1.mod.server;
using WindowsFormsApp1.server;
using static SQLite.SQLite3;
@@ -27,6 +29,22 @@ namespace WindowsFormsApp1
{
private Thread thread_plc1;
private Thread thread_plc2;
+ private SerialPort ScanPort;
+ /*
+ *
+ * COM1 -- COM口名称
+ * 9600 波特率
+ * 校验位 Parity.None == 无
+ * 数据位 :8
+ *
+ * 测试称重
+ * 解除注释
+ * //port.DataReceived += new SerialDataReceivedEventHandler(port_Receive);
+ * //port.Open();
+ * //port.WriteLine("SI");
+ *
+ */
+
public MainForm()
{
InitializeComponent();
@@ -41,6 +59,10 @@ namespace WindowsFormsApp1
Formrecover();
+
+
+
+
线别.Text = "线别:" + Init.t_Line.linename;
段别.Text = "段别:" + Init.t_Line.linemode;
机台编号.Text = "机台编号:" + Init.t_Line.linecode;
@@ -63,6 +85,7 @@ namespace WindowsFormsApp1
continue;
}
+ #region PLC链接及读取
SiemensHelp siemensHelp = Plc.plchelp;
var openresult = siemensHelp.OpenConn();
@@ -102,7 +125,74 @@ namespace WindowsFormsApp1
PLC链接状态.Text = "PLC链接状态:OK";
PLC链接状态.BackColor = SystemColors.Control;
PLC通讯时间.Text = "PLC通讯时间:" + Plc_Time.ToString("MM-dd HH:mm:ss");
+ #endregion
+ ApiClient apiClient = new ApiClient();
+ otherdata otherdata = new otherdata();
+
+ #region 机台状态及报警
+ //机台状态
+ 机台状态.Text = "机台状态:" + Enum.GetName(typeof(plcstatus), Init.Plcstatus);
+ int oldstatus = Init.Plcstatus;
+ DateTime oldPlcstatus_LastTime = Init.Plcstatus_LastTime;
+ //状态+报警
+ if (oldstatus != PlcData.Read_Status || (Plc_Time - oldPlcstatus_LastTime).TotalSeconds > 5)
+ {
+ //反馈状态
+ otherdata.Plc_Status = PlcData.Read_Status;
+ var statusresult = apiClient.CallFunctionByName("Status", PlcData, otherdata);
+ if (statusresult.Success)
+ {
+ Init.Plcstatus = PlcData.Read_Status;
+ Init.Plcstatus_LastTime = DateTime.Now;
+ MES链接状态.Text = "MES链接状态:OK";
+ MES链接状态.BackColor = SystemColors.Control;
+ MES通讯时间.Text = "MES通讯时间:" + DateTime.Now.ToString("MM-dd HH:mm:ss");
+ MES_MsgfORM("Status", statusresult.Mesresult, statusresult.Requesttime);
+ }
+ else
+ {
+ MES链接状态.Text = "MES链接状态:NG";
+ MES链接状态.BackColor = Color.Red;
+ LogExecute.logNet.WriteError($"MES通讯异常!");
+ }
+ }
+ //机台报警
+ if (PlcData.Read_Status == (short)plcstatus.停机)
+ {
+ 机台状态.BackColor = Color.Red;
+ if (oldstatus != (short)plcstatus.停机)
+ {
+ //反馈报警
+ List list = new List();
+///////////////////////////////测试用
+ list.Add("M03CVSO-01");
+ otherdata.Plc_ErrorMsgs = list;
+ var statusresult = apiClient.CallFunctionByName("Alarm", PlcData, otherdata);
+ if (statusresult.Success)
+ {
+ Init.Plcstatus = PlcData.Read_Status;
+ Init.Plcstatus_LastTime = DateTime.Now;
+ MES链接状态.Text = "MES链接状态:OK";
+ MES链接状态.BackColor = SystemColors.Control;
+ MES通讯时间.Text = "MES通讯时间:" + DateTime.Now.ToString("MM-dd HH:mm:ss");
+ MES_MsgfORM("Alarm", statusresult.Mesresult, statusresult.Requesttime);
+ }
+ else
+ {
+ MES链接状态.Text = "MES链接状态:NG";
+ MES链接状态.BackColor = Color.Red;
+ LogExecute.logNet.WriteError($"MES通讯异常!");
+ }
+ }
+ continue;
+ }
+ else
+ {
+ 机台状态.BackColor = SystemColors.Control;
+ }
+ #endregion
+ #region 判断及查找流程
if (PlcData.Read_Trigger == 0 && PlcData.Write_Status == 0)
{
continue;
@@ -123,64 +213,6 @@ namespace WindowsFormsApp1
}
continue;
}
- ApiClient apiClient = new ApiClient();
- otherdata otherdata = new otherdata();
- otherdata.JS_SN = "12345";
-
-
-
-
- //状态+报警
- if (Init.Plcstatus != PlcData.Read_Status || (Plc_Time - Init.Plcstatus_LastTime).TotalSeconds > 15)
- {
- //反馈状态
- var statusresult = apiClient.CallFunctionByName("Status", PlcData, otherdata);
- if (statusresult.Success)
- {
- MES链接状态.Text = "MES链接状态:OK";
- MES链接状态.BackColor = SystemColors.Control;
- MES通讯时间.Text = "MES通讯时间:" + DateTime.Now.ToString("MM-dd HH:mm:ss");
- MES_MsgfORM("Status", statusresult.Mesresult, statusresult.Requesttime);
- }
- else
- {
- MES链接状态.Text = "MES链接状态:NG";
- MES链接状态.BackColor = Color.Red;
- LogExecute.logNet.WriteError($"MES通讯异常!");
- }
- }
- if (Init.Plcstatus == (short)plcstatus.运行 && PlcData.Read_Status == (short)plcstatus.停机)
- {
- 机台状态.BackColor = Color.Red;
- //反馈报警
- var statusresult = apiClient.CallFunctionByName("Alarm", PlcData, otherdata);
- if (statusresult.Success)
- {
- MES链接状态.Text = "MES链接状态:OK";
- MES链接状态.BackColor = SystemColors.Control;
- MES通讯时间.Text = "MES通讯时间:" + DateTime.Now.ToString("MM-dd HH:mm:ss");
- MES_MsgfORM("Alarm", statusresult.Mesresult, statusresult.Requesttime);
- }
- else
- {
- MES链接状态.Text = "MES链接状态:NG";
- MES链接状态.BackColor = Color.Red;
- LogExecute.logNet.WriteError($"MES通讯异常!");
- }
- continue;
- }
- else
- {
- 机台状态.BackColor = SystemColors.Control;
- }
-
- Init.Plcstatus = PlcData.Read_Status;
- Init.Plcstatus_LastTime = DateTime.Now;
- 机台状态.Text = Enum.GetName(typeof(plcstatus), Init.Plcstatus);
-
-
-
-
var nowflow = Init.t_Flows.FirstOrDefault(a => a.hopestatus == PlcData.Read_Trigger);
if (nowflow == null)
{
@@ -193,12 +225,21 @@ namespace WindowsFormsApp1
LogExecute.logNet.WriteError($"未找到当前期望接口ID {nowflow.hopeinterfaceid},对应的接口!");
continue;
}
+ #endregion
+
+ if(nowinterface.code == "SN_CheckIN")
+ {
+ 请扫描LOT号.Enabled = true;
+ ScanPort.Read();
+
+
+ }
+
+
-
-
var result = apiClient.CallFunctionByName(nowinterface.code,PlcData, otherdata);
if (result.Success)
{
@@ -284,6 +325,42 @@ namespace WindowsFormsApp1
return;
}
+
+ SQLiteHelper sQLiteHelper_serialport = new db.SQLiteHelper();
+ var serialport_result = sQLiteHelper_serialport.QueryAll();
+ if (!serialport_result.Success)
+ {
+ MessageBox.Show("无法初始化COM口信息,无法开始处理!");
+ return;
+ }
+
+ try
+ {
+ var scanport = serialport_result.Data.FirstOrDefault(a=>a.name == "Scan");
+ if (scanport != null)
+ {
+ if (scanport.enable)
+ {
+ Enum.TryParse(scanport.parity, out Parity parity);
+ ScanPort = new SerialPort(scanport.portName, scanport.baudRate, parity, scanport.dataBits);
+ if (!ScanPort.IsOpen)
+ {
+ //port?.Open();
+ 底部注释1.Text = "扫码枪COM-Ready";
+ 底部注释1.Visible = true;
+ }
+ }
+ }
+
+ }
+ catch(Exception ex)
+ {
+ MessageBox.Show("无法开启扫码枪,无法开始处理!" + ex.Message);
+ return;
+ }
+
+
+
Init.t_Plc1 = plc_result.Data;
Init.t_Plc1.plchelp = new SiemensHelp(Init.t_Plc1.plcip, Init.t_Plc1.timeout);
Init.t_Plc2 = plc_result2.Data;
@@ -335,6 +412,9 @@ namespace WindowsFormsApp1
}
Init.isrunning2 = false;
+ ScanPort?.Close();
+
+
Thread.Sleep(500);
开始处理.Text = "开始处理";
开始处理.BackColor = Color.Green;
@@ -391,6 +471,12 @@ namespace WindowsFormsApp1
USER_Manage uSER_Manage = new USER_Manage();
uSER_Manage.ShowDialog();
}
+
+ private void 扫码枪配置ToolStripMenuItem1_Click(object sender, EventArgs e)
+ {
+ SerialPort_Manage serialPort_Manage = new SerialPort_Manage();
+ serialPort_Manage.ShowDialog();
+ }
#endregion
#region 页面-布局、日志等
private void LogNet_BeforeSaveToFile(object sender, HslEventArgs e)
@@ -439,8 +525,6 @@ namespace WindowsFormsApp1
{
当前时间.Text = "当前时间:" + DateTime.Now.ToString("MM-dd HH:mm:ss");
}
- #endregion
-
public void Formrecover()
{
MES链接状态.Text = "MES链接状态:None";
@@ -487,9 +571,9 @@ namespace WindowsFormsApp1
}
- public void MES_MsgfORM(string name,mesresult result,DateTime dateTime)
+ public void MES_MsgfORM(string name, mesresult result, DateTime dateTime)
{
- if (事件1.Text.Contains("事件"))
+ if (事件1.Text == name)
{
事件1.Visible = true;
事件1结果.Visible = true;
@@ -498,7 +582,7 @@ namespace WindowsFormsApp1
事件1时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
事件1结果.Text = result.ToString();
}
- else if (事件2.Text.Contains("事件"))
+ else if (事件2.Text == name)
{
事件2.Visible = true;
事件2结果.Visible = true;
@@ -507,7 +591,7 @@ namespace WindowsFormsApp1
事件2时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
事件2结果.Text = result.ToString();
}
- else if (事件3.Text.Contains("事件"))
+ else if (事件3.Text == name)
{
事件3.Visible = true;
事件3结果.Visible = true;
@@ -516,7 +600,7 @@ namespace WindowsFormsApp1
事件3时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
事件3结果.Text = result.ToString();
}
- else if (事件4.Text.Contains("事件"))
+ else if (事件4.Text == name)
{
事件4.Visible = true;
事件4结果.Visible = true;
@@ -527,37 +611,75 @@ namespace WindowsFormsApp1
}
else
{
- 事件1.Visible = true;
- 事件1结果.Visible = true;
- 事件1时间.Visible = true;
- 事件1.Text = name;
- 事件1时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
- 事件1结果.Text = result.ToString();
+ if (事件1.Text.Contains("事件"))
+ {
+ 事件1.Visible = true;
+ 事件1结果.Visible = true;
+ 事件1时间.Visible = true;
+ 事件1.Text = name;
+ 事件1时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
+ 事件1结果.Text = result.ToString();
+ }
+ else if (事件2.Text.Contains("事件"))
+ {
+ 事件2.Visible = true;
+ 事件2结果.Visible = true;
+ 事件2时间.Visible = true;
+ 事件2.Text = name;
+ 事件2时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
+ 事件2结果.Text = result.ToString();
+ }
+ else if (事件3.Text.Contains("事件"))
+ {
+ 事件3.Visible = true;
+ 事件3结果.Visible = true;
+ 事件3时间.Visible = true;
+ 事件3.Text = name;
+ 事件3时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
+ 事件3结果.Text = result.ToString();
+ }
+ else if (事件4.Text.Contains("事件"))
+ {
+ 事件4.Visible = true;
+ 事件4结果.Visible = true;
+ 事件4时间.Visible = true;
+ 事件4.Text = name;
+ 事件4时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
+ 事件4结果.Text = result.ToString();
+ }
+ else
+ {
+ 事件1.Visible = true;
+ 事件1结果.Visible = true;
+ 事件1时间.Visible = true;
+ 事件1.Text = name;
+ 事件1时间.Text = dateTime.ToString("MM-dd HH:mm:ss");
+ 事件1结果.Text = result.ToString();
- 事件2.Visible = false;
- 事件2结果.Visible = false;
- 事件2时间.Visible = false;
- 事件2.Text = "事件2";
- 事件2时间.Text = "事件2时间";
- 事件2结果.Text = "OK";
+ 事件2.Visible = false;
+ 事件2结果.Visible = false;
+ 事件2时间.Visible = false;
+ 事件2.Text = "事件2";
+ 事件2时间.Text = "事件2时间";
+ 事件2结果.Text = "OK";
- 事件3.Visible = false;
- 事件3结果.Visible = false;
- 事件3时间.Visible = false;
- 事件3.Text = "事件3";
- 事件3时间.Text = "事件3时间";
- 事件3结果.Text = "OK";
-
- 事件4.Visible = false;
- 事件4结果.Visible = false;
- 事件4时间.Visible = false;
- 事件4.Text = "事件4";
- 事件4时间.Text = "事件4时间";
- 事件4结果.Text = "OK";
+ 事件3.Visible = false;
+ 事件3结果.Visible = false;
+ 事件3时间.Visible = false;
+ 事件3.Text = "事件3";
+ 事件3时间.Text = "事件3时间";
+ 事件3结果.Text = "OK";
+ 事件4.Visible = false;
+ 事件4结果.Visible = false;
+ 事件4时间.Visible = false;
+ 事件4.Text = "事件4";
+ 事件4时间.Text = "事件4时间";
+ 事件4结果.Text = "OK";
+ }
}
-
-
}
+ #endregion
+
}
}
diff --git a/WindowsFormsApp1/Program.cs b/WindowsFormsApp1/Program.cs
index dd8be8a..d649712 100644
--- a/WindowsFormsApp1/Program.cs
+++ b/WindowsFormsApp1/Program.cs
@@ -51,7 +51,7 @@ namespace WindowsFormsApp1
public static int errinterface1 = 0;
public static int errinterface2 = 0;
- public static short Plcstatus = 0;
+ public static short Plcstatus = -1;
public static DateTime Plcstatus_LastTime = DateTime.Now;
}
diff --git a/WindowsFormsApp1/db/MES_PLC.db b/WindowsFormsApp1/db/MES_PLC.db
index fbf34b1..b20bc4b 100644
Binary files a/WindowsFormsApp1/db/MES_PLC.db and b/WindowsFormsApp1/db/MES_PLC.db differ
diff --git a/WindowsFormsApp1/form/FLOW_Manage.Designer.cs b/WindowsFormsApp1/form/FLOW_Manage.Designer.cs
index ef7942e..4068ca9 100644
--- a/WindowsFormsApp1/form/FLOW_Manage.Designer.cs
+++ b/WindowsFormsApp1/form/FLOW_Manage.Designer.cs
@@ -32,16 +32,16 @@
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
+ this.关闭 = new System.Windows.Forms.Button();
+ this.保存 = new System.Windows.Forms.Button();
+ this.查询 = new System.Windows.Forms.Button();
+ this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.flowid = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.setp = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.hopestatus = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.hopeinterfaceid = new System.Windows.Forms.DataGridViewComboBoxColumn();
this.errstatus = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.errinterfaceid = new System.Windows.Forms.DataGridViewComboBoxColumn();
- this.关闭 = new System.Windows.Forms.Button();
- this.保存 = new System.Windows.Forms.Button();
- this.查询 = new System.Windows.Forms.Button();
- this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
this.tableLayoutPanel1.SuspendLayout();
this.SuspendLayout();
@@ -79,72 +79,23 @@
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dataGridView1.DefaultCellStyle = dataGridViewCellStyle3;
- this.dataGridView1.Location = new System.Drawing.Point(3, 3);
+ this.dataGridView1.Location = new System.Drawing.Point(6, 5);
+ this.dataGridView1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.RowHeadersWidth = 72;
this.tableLayoutPanel1.SetRowSpan(this.dataGridView1, 4);
this.dataGridView1.RowTemplate.Height = 23;
- this.dataGridView1.Size = new System.Drawing.Size(1686, 1011);
+ this.dataGridView1.Size = new System.Drawing.Size(1557, 818);
this.dataGridView1.TabIndex = 1;
//
- // flowid
- //
- this.flowid.DataPropertyName = "flowid";
- this.flowid.HeaderText = "流程序号";
- this.flowid.MinimumWidth = 9;
- this.flowid.Name = "flowid";
- this.flowid.ReadOnly = true;
- this.flowid.Width = 175;
- //
- // setp
- //
- this.setp.DataPropertyName = "setp";
- this.setp.HeaderText = "步骤";
- this.setp.MinimumWidth = 9;
- this.setp.Name = "setp";
- this.setp.ReadOnly = true;
- this.setp.Width = 175;
- //
- // hopestatus
- //
- this.hopestatus.DataPropertyName = "hopestatus";
- this.hopestatus.HeaderText = "期望PLC值";
- this.hopestatus.MinimumWidth = 9;
- this.hopestatus.Name = "hopestatus";
- this.hopestatus.Width = 150;
- //
- // hopeinterfaceid
- //
- this.hopeinterfaceid.DataPropertyName = "hopeinterfaceid";
- this.hopeinterfaceid.HeaderText = "成功调用接口";
- this.hopeinterfaceid.MinimumWidth = 9;
- this.hopeinterfaceid.Name = "hopeinterfaceid";
- this.hopeinterfaceid.Width = 200;
- //
- // errstatus
- //
- this.errstatus.DataPropertyName = "errstatus";
- this.errstatus.HeaderText = "错误PLC值";
- this.errstatus.MinimumWidth = 9;
- this.errstatus.Name = "errstatus";
- this.errstatus.Width = 150;
- //
- // errinterfaceid
- //
- this.errinterfaceid.DataPropertyName = "errinterfaceid";
- this.errinterfaceid.HeaderText = "错误调用接口";
- this.errinterfaceid.MinimumWidth = 9;
- this.errinterfaceid.Name = "errinterfaceid";
- this.errinterfaceid.Resizable = System.Windows.Forms.DataGridViewTriState.True;
- this.errinterfaceid.Width = 200;
- //
// 关闭
//
this.关闭.Anchor = System.Windows.Forms.AnchorStyles.None;
this.关闭.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.关闭.Location = new System.Drawing.Point(1740, 950);
+ this.关闭.Location = new System.Drawing.Point(1575, 708);
+ this.关闭.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.关闭.Name = "关闭";
- this.关闭.Size = new System.Drawing.Size(92, 41);
+ this.关闭.Size = new System.Drawing.Size(163, 72);
this.关闭.TabIndex = 6;
this.关闭.Text = "关闭";
this.关闭.UseVisualStyleBackColor = true;
@@ -154,9 +105,10 @@
//
this.保存.Anchor = System.Windows.Forms.AnchorStyles.None;
this.保存.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.保存.Location = new System.Drawing.Point(1740, 857);
+ this.保存.Location = new System.Drawing.Point(1575, 542);
+ this.保存.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.保存.Name = "保存";
- this.保存.Size = new System.Drawing.Size(92, 41);
+ this.保存.Size = new System.Drawing.Size(163, 72);
this.保存.TabIndex = 5;
this.保存.Text = "保存";
this.保存.UseVisualStyleBackColor = true;
@@ -166,9 +118,10 @@
//
this.查询.Anchor = System.Windows.Forms.AnchorStyles.None;
this.查询.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.查询.Location = new System.Drawing.Point(1740, 22);
+ this.查询.Location = new System.Drawing.Point(1575, 46);
+ this.查询.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.查询.Name = "查询";
- this.查询.Size = new System.Drawing.Size(92, 41);
+ this.查询.Size = new System.Drawing.Size(163, 72);
this.查询.TabIndex = 4;
this.查询.Text = "查询";
this.查询.UseVisualStyleBackColor = true;
@@ -183,23 +136,76 @@
this.tableLayoutPanel1.Controls.Add(this.关闭, 1, 3);
this.tableLayoutPanel1.Controls.Add(this.dataGridView1, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.保存, 1, 2);
- this.tableLayoutPanel1.Location = new System.Drawing.Point(12, 12);
+ this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
+ this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 4;
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10.22067F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 89.77933F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 94F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 91F));
- this.tableLayoutPanel1.Size = new System.Drawing.Size(1880, 1017);
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(1744, 828);
this.tableLayoutPanel1.TabIndex = 7;
//
+ // flowid
+ //
+ this.flowid.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.flowid.DataPropertyName = "flowid";
+ this.flowid.HeaderText = "流程序号";
+ this.flowid.MinimumWidth = 9;
+ this.flowid.Name = "flowid";
+ this.flowid.ReadOnly = true;
+ //
+ // setp
+ //
+ this.setp.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.setp.DataPropertyName = "setp";
+ this.setp.HeaderText = "步骤";
+ this.setp.MinimumWidth = 9;
+ this.setp.Name = "setp";
+ //
+ // hopestatus
+ //
+ this.hopestatus.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.hopestatus.DataPropertyName = "hopestatus";
+ this.hopestatus.HeaderText = "期望PLC值";
+ this.hopestatus.MinimumWidth = 9;
+ this.hopestatus.Name = "hopestatus";
+ //
+ // hopeinterfaceid
+ //
+ this.hopeinterfaceid.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.hopeinterfaceid.DataPropertyName = "hopeinterfaceid";
+ this.hopeinterfaceid.HeaderText = "成功调用接口";
+ this.hopeinterfaceid.MinimumWidth = 9;
+ this.hopeinterfaceid.Name = "hopeinterfaceid";
+ //
+ // errstatus
+ //
+ this.errstatus.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.errstatus.DataPropertyName = "errstatus";
+ this.errstatus.HeaderText = "错误PLC值";
+ this.errstatus.MinimumWidth = 9;
+ this.errstatus.Name = "errstatus";
+ //
+ // errinterfaceid
+ //
+ this.errinterfaceid.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.errinterfaceid.DataPropertyName = "errinterfaceid";
+ this.errinterfaceid.HeaderText = "错误调用接口";
+ this.errinterfaceid.MinimumWidth = 9;
+ this.errinterfaceid.Name = "errinterfaceid";
+ this.errinterfaceid.Resizable = System.Windows.Forms.DataGridViewTriState.True;
+ //
// FLOW_Manage
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1904, 1041);
+ this.ClientSize = new System.Drawing.Size(1744, 828);
this.Controls.Add(this.tableLayoutPanel1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+ this.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.Name = "FLOW_Manage";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "FLOW_Mange";
@@ -216,12 +222,12 @@
private System.Windows.Forms.Button 关闭;
private System.Windows.Forms.Button 保存;
private System.Windows.Forms.Button 查询;
+ private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.DataGridViewTextBoxColumn flowid;
private System.Windows.Forms.DataGridViewTextBoxColumn setp;
private System.Windows.Forms.DataGridViewTextBoxColumn hopestatus;
private System.Windows.Forms.DataGridViewComboBoxColumn hopeinterfaceid;
private System.Windows.Forms.DataGridViewTextBoxColumn errstatus;
private System.Windows.Forms.DataGridViewComboBoxColumn errinterfaceid;
- private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
}
}
\ No newline at end of file
diff --git a/WindowsFormsApp1/form/LINE_Manage.Designer.cs b/WindowsFormsApp1/form/LINE_Manage.Designer.cs
index 302c222..f957edf 100644
--- a/WindowsFormsApp1/form/LINE_Manage.Designer.cs
+++ b/WindowsFormsApp1/form/LINE_Manage.Designer.cs
@@ -35,6 +35,7 @@
this.保存 = new System.Windows.Forms.Button();
this.查询 = new System.Windows.Forms.Button();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
+ this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.id = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.linename = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.linecode = new System.Windows.Forms.DataGridViewTextBoxColumn();
@@ -43,7 +44,6 @@
this.plcid1 = new System.Windows.Forms.DataGridViewComboBoxColumn();
this.plcid2 = new System.Windows.Forms.DataGridViewComboBoxColumn();
this.flowid = new System.Windows.Forms.DataGridViewComboBoxColumn();
- this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
this.tableLayoutPanel1.SuspendLayout();
this.SuspendLayout();
@@ -52,9 +52,10 @@
//
this.关闭.Anchor = System.Windows.Forms.AnchorStyles.None;
this.关闭.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.关闭.Location = new System.Drawing.Point(1743, 958);
+ this.关闭.Location = new System.Drawing.Point(1604, 709);
+ this.关闭.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.关闭.Name = "关闭";
- this.关闭.Size = new System.Drawing.Size(92, 41);
+ this.关闭.Size = new System.Drawing.Size(162, 72);
this.关闭.TabIndex = 10;
this.关闭.Text = "关闭";
this.关闭.UseVisualStyleBackColor = true;
@@ -64,9 +65,10 @@
//
this.保存.Anchor = System.Windows.Forms.AnchorStyles.None;
this.保存.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.保存.Location = new System.Drawing.Point(1743, 886);
+ this.保存.Location = new System.Drawing.Point(1604, 542);
+ this.保存.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.保存.Name = "保存";
- this.保存.Size = new System.Drawing.Size(92, 41);
+ this.保存.Size = new System.Drawing.Size(162, 72);
this.保存.TabIndex = 9;
this.保存.Text = "保存";
this.保存.UseVisualStyleBackColor = true;
@@ -76,9 +78,10 @@
//
this.查询.Anchor = System.Windows.Forms.AnchorStyles.None;
this.查询.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.查询.Location = new System.Drawing.Point(1743, 24);
+ this.查询.Location = new System.Drawing.Point(1604, 46);
+ this.查询.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.查询.Name = "查询";
- this.查询.Size = new System.Drawing.Size(92, 41);
+ this.查询.Size = new System.Drawing.Size(162, 72);
this.查询.TabIndex = 8;
this.查询.Text = "查询";
this.查询.UseVisualStyleBackColor = true;
@@ -119,81 +122,15 @@
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dataGridView1.DefaultCellStyle = dataGridViewCellStyle3;
- this.dataGridView1.Location = new System.Drawing.Point(3, 3);
+ this.dataGridView1.Location = new System.Drawing.Point(6, 5);
+ this.dataGridView1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.RowHeadersWidth = 72;
this.tableLayoutPanel1.SetRowSpan(this.dataGridView1, 4);
this.dataGridView1.RowTemplate.Height = 23;
- this.dataGridView1.Size = new System.Drawing.Size(1689, 1011);
+ this.dataGridView1.Size = new System.Drawing.Size(1584, 819);
this.dataGridView1.TabIndex = 7;
//
- // id
- //
- this.id.DataPropertyName = "id";
- this.id.HeaderText = "序号";
- this.id.MinimumWidth = 9;
- this.id.Name = "id";
- this.id.ReadOnly = true;
- this.id.Width = 175;
- //
- // linename
- //
- this.linename.DataPropertyName = "linename";
- this.linename.HeaderText = "名称";
- this.linename.MinimumWidth = 9;
- this.linename.Name = "linename";
- this.linename.ReadOnly = true;
- this.linename.Width = 175;
- //
- // linecode
- //
- this.linecode.DataPropertyName = "linecode";
- this.linecode.HeaderText = "产线编码";
- this.linecode.MinimumWidth = 9;
- this.linecode.Name = "linecode";
- this.linecode.Width = 150;
- //
- // linetype
- //
- this.linetype.DataPropertyName = "linetype";
- this.linetype.HeaderText = "产线类型";
- this.linetype.MinimumWidth = 9;
- this.linetype.Name = "linetype";
- this.linetype.Width = 150;
- //
- // linemode
- //
- this.linemode.DataPropertyName = "linemode";
- this.linemode.HeaderText = "模组";
- this.linemode.MinimumWidth = 9;
- this.linemode.Name = "linemode";
- this.linemode.Width = 175;
- //
- // plcid1
- //
- this.plcid1.DataPropertyName = "plcid1";
- this.plcid1.HeaderText = "关联PLC1";
- this.plcid1.MinimumWidth = 9;
- this.plcid1.Name = "plcid1";
- this.plcid1.Width = 200;
- //
- // plcid2
- //
- this.plcid2.DataPropertyName = "plcid2";
- this.plcid2.HeaderText = "关联PLC2";
- this.plcid2.MinimumWidth = 9;
- this.plcid2.Name = "plcid2";
- this.plcid2.Width = 175;
- //
- // flowid
- //
- this.flowid.DataPropertyName = "flowid";
- this.flowid.HeaderText = "关联流程";
- this.flowid.MinimumWidth = 9;
- this.flowid.Name = "flowid";
- this.flowid.Resizable = System.Windows.Forms.DataGridViewTriState.True;
- this.flowid.Width = 200;
- //
// tableLayoutPanel1
//
this.tableLayoutPanel1.ColumnCount = 2;
@@ -203,24 +140,93 @@
this.tableLayoutPanel1.Controls.Add(this.dataGridView1, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.查询, 1, 0);
this.tableLayoutPanel1.Controls.Add(this.保存, 1, 2);
- this.tableLayoutPanel1.Location = new System.Drawing.Point(8, 12);
+ this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
+ this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 4;
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10.20642F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 89.79358F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 69F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 75F));
- this.tableLayoutPanel1.Size = new System.Drawing.Size(1884, 1017);
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(1774, 829);
this.tableLayoutPanel1.TabIndex = 11;
//
+ // id
+ //
+ this.id.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.id.DataPropertyName = "id";
+ this.id.HeaderText = "序号";
+ this.id.MinimumWidth = 9;
+ this.id.Name = "id";
+ this.id.ReadOnly = true;
+ //
+ // linename
+ //
+ this.linename.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.linename.DataPropertyName = "linename";
+ this.linename.HeaderText = "名称";
+ this.linename.MinimumWidth = 9;
+ this.linename.Name = "linename";
+ this.linename.ReadOnly = true;
+ //
+ // linecode
+ //
+ this.linecode.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.linecode.DataPropertyName = "linecode";
+ this.linecode.HeaderText = "产线编码";
+ this.linecode.MinimumWidth = 9;
+ this.linecode.Name = "linecode";
+ //
+ // linetype
+ //
+ this.linetype.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.linetype.DataPropertyName = "linetype";
+ this.linetype.HeaderText = "产线类型";
+ this.linetype.MinimumWidth = 9;
+ this.linetype.Name = "linetype";
+ //
+ // linemode
+ //
+ this.linemode.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.linemode.DataPropertyName = "linemode";
+ this.linemode.HeaderText = "模组";
+ this.linemode.MinimumWidth = 9;
+ this.linemode.Name = "linemode";
+ //
+ // plcid1
+ //
+ this.plcid1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.plcid1.DataPropertyName = "plcid1";
+ this.plcid1.HeaderText = "关联PLC1";
+ this.plcid1.MinimumWidth = 9;
+ this.plcid1.Name = "plcid1";
+ //
+ // plcid2
+ //
+ this.plcid2.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.plcid2.DataPropertyName = "plcid2";
+ this.plcid2.HeaderText = "关联PLC2";
+ this.plcid2.MinimumWidth = 9;
+ this.plcid2.Name = "plcid2";
+ //
+ // flowid
+ //
+ this.flowid.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.flowid.DataPropertyName = "flowid";
+ this.flowid.HeaderText = "关联流程";
+ this.flowid.MinimumWidth = 9;
+ this.flowid.Name = "flowid";
+ this.flowid.Resizable = System.Windows.Forms.DataGridViewTriState.True;
+ //
// LINE_Manage
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1904, 1041);
+ this.ClientSize = new System.Drawing.Size(1774, 829);
this.Controls.Add(this.tableLayoutPanel1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
- this.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
+ this.Margin = new System.Windows.Forms.Padding(4);
this.Name = "LINE_Manage";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "LINE_Mange";
@@ -237,6 +243,7 @@
private System.Windows.Forms.Button 保存;
private System.Windows.Forms.Button 查询;
private System.Windows.Forms.DataGridView dataGridView1;
+ private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.DataGridViewTextBoxColumn id;
private System.Windows.Forms.DataGridViewTextBoxColumn linename;
private System.Windows.Forms.DataGridViewTextBoxColumn linecode;
@@ -245,6 +252,5 @@
private System.Windows.Forms.DataGridViewComboBoxColumn plcid1;
private System.Windows.Forms.DataGridViewComboBoxColumn plcid2;
private System.Windows.Forms.DataGridViewComboBoxColumn flowid;
- private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
}
}
\ No newline at end of file
diff --git a/WindowsFormsApp1/form/MES_URL.Designer.cs b/WindowsFormsApp1/form/MES_URL.Designer.cs
index b01a81a..9ef4ea2 100644
--- a/WindowsFormsApp1/form/MES_URL.Designer.cs
+++ b/WindowsFormsApp1/form/MES_URL.Designer.cs
@@ -34,12 +34,12 @@
this.保存 = new System.Windows.Forms.Button();
this.查询 = new System.Windows.Forms.Button();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
+ this.关闭 = new System.Windows.Forms.Button();
+ this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.id = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.name = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.code = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.url = new System.Windows.Forms.DataGridViewTextBoxColumn();
- this.关闭 = new System.Windows.Forms.Button();
- this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
this.tableLayoutPanel1.SuspendLayout();
this.SuspendLayout();
@@ -48,9 +48,10 @@
//
this.保存.Anchor = System.Windows.Forms.AnchorStyles.None;
this.保存.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.保存.Location = new System.Drawing.Point(1739, 877);
+ this.保存.Location = new System.Drawing.Point(1488, 528);
+ this.保存.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.保存.Name = "保存";
- this.保存.Size = new System.Drawing.Size(91, 32);
+ this.保存.Size = new System.Drawing.Size(153, 56);
this.保存.TabIndex = 1;
this.保存.Text = "保存";
this.保存.UseVisualStyleBackColor = true;
@@ -60,9 +61,10 @@
//
this.查询.Anchor = System.Windows.Forms.AnchorStyles.None;
this.查询.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.查询.Location = new System.Drawing.Point(1739, 30);
+ this.查询.Location = new System.Drawing.Point(1488, 51);
+ this.查询.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.查询.Name = "查询";
- this.查询.Size = new System.Drawing.Size(91, 32);
+ this.查询.Size = new System.Drawing.Size(153, 56);
this.查询.TabIndex = 3;
this.查询.Text = "查询";
this.查询.UseVisualStyleBackColor = true;
@@ -74,9 +76,6 @@
this.dataGridView1.AllowUserToDeleteRows = false;
dataGridViewCellStyle1.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.dataGridView1.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle1;
- this.dataGridView1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Control;
dataGridViewCellStyle2.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
@@ -99,56 +98,24 @@
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dataGridView1.DefaultCellStyle = dataGridViewCellStyle3;
- this.dataGridView1.Location = new System.Drawing.Point(3, 3);
+ this.dataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.dataGridView1.Location = new System.Drawing.Point(6, 5);
+ this.dataGridView1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.RowHeadersWidth = 72;
this.tableLayoutPanel1.SetRowSpan(this.dataGridView1, 4);
this.dataGridView1.RowTemplate.Height = 23;
- this.dataGridView1.Size = new System.Drawing.Size(1685, 1010);
+ this.dataGridView1.Size = new System.Drawing.Size(1470, 785);
this.dataGridView1.TabIndex = 0;
//
- // id
- //
- this.id.DataPropertyName = "id";
- this.id.HeaderText = "序号";
- this.id.MinimumWidth = 9;
- this.id.Name = "id";
- this.id.ReadOnly = true;
- this.id.Width = 175;
- //
- // name
- //
- this.name.DataPropertyName = "name";
- this.name.HeaderText = "名称";
- this.name.MinimumWidth = 9;
- this.name.Name = "name";
- this.name.ReadOnly = true;
- this.name.Width = 175;
- //
- // code
- //
- this.code.DataPropertyName = "code";
- this.code.HeaderText = "接口";
- this.code.MinimumWidth = 9;
- this.code.Name = "code";
- this.code.ReadOnly = true;
- this.code.Width = 175;
- //
- // url
- //
- this.url.DataPropertyName = "url";
- this.url.HeaderText = "网址";
- this.url.MinimumWidth = 9;
- this.url.Name = "url";
- this.url.Width = 500;
- //
// 关闭
//
this.关闭.Anchor = System.Windows.Forms.AnchorStyles.None;
this.关闭.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.关闭.Location = new System.Drawing.Point(1739, 959);
+ this.关闭.Location = new System.Drawing.Point(1488, 687);
+ this.关闭.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.关闭.Name = "关闭";
- this.关闭.Size = new System.Drawing.Size(91, 32);
+ this.关闭.Size = new System.Drawing.Size(153, 56);
this.关闭.TabIndex = 2;
this.关闭.Text = "关闭";
this.关闭.UseVisualStyleBackColor = true;
@@ -163,23 +130,61 @@
this.tableLayoutPanel1.Controls.Add(this.查询, 1, 0);
this.tableLayoutPanel1.Controls.Add(this.关闭, 1, 3);
this.tableLayoutPanel1.Controls.Add(this.保存, 1, 2);
- this.tableLayoutPanel1.Location = new System.Drawing.Point(13, 13);
+ this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
+ this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 4;
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10.91549F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 89.08451F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 82F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 81F));
- this.tableLayoutPanel1.Size = new System.Drawing.Size(1879, 1016);
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(1647, 795);
this.tableLayoutPanel1.TabIndex = 4;
//
+ // id
+ //
+ this.id.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.id.DataPropertyName = "id";
+ this.id.HeaderText = "序号";
+ this.id.MinimumWidth = 9;
+ this.id.Name = "id";
+ this.id.ReadOnly = true;
+ //
+ // name
+ //
+ this.name.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.name.DataPropertyName = "name";
+ this.name.HeaderText = "名称";
+ this.name.MinimumWidth = 9;
+ this.name.Name = "name";
+ this.name.ReadOnly = true;
+ //
+ // code
+ //
+ this.code.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.code.DataPropertyName = "code";
+ this.code.HeaderText = "接口";
+ this.code.MinimumWidth = 9;
+ this.code.Name = "code";
+ this.code.ReadOnly = true;
+ //
+ // url
+ //
+ this.url.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.url.DataPropertyName = "url";
+ this.url.HeaderText = "网址";
+ this.url.MinimumWidth = 9;
+ this.url.Name = "url";
+ //
// MES_URL
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1904, 1041);
+ this.ClientSize = new System.Drawing.Size(1647, 795);
this.Controls.Add(this.tableLayoutPanel1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+ this.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.Name = "MES_URL";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "MES_URL";
@@ -194,11 +199,11 @@
private System.Windows.Forms.Button 保存;
private System.Windows.Forms.Button 查询;
private System.Windows.Forms.DataGridView dataGridView1;
+ private System.Windows.Forms.Button 关闭;
+ private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.DataGridViewTextBoxColumn id;
private System.Windows.Forms.DataGridViewTextBoxColumn name;
private System.Windows.Forms.DataGridViewTextBoxColumn code;
private System.Windows.Forms.DataGridViewTextBoxColumn url;
- private System.Windows.Forms.Button 关闭;
- private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
}
}
\ No newline at end of file
diff --git a/WindowsFormsApp1/form/PLCADDRESS_Manage.Designer.cs b/WindowsFormsApp1/form/PLCADDRESS_Manage.Designer.cs
index 8695c8b..3e08da6 100644
--- a/WindowsFormsApp1/form/PLCADDRESS_Manage.Designer.cs
+++ b/WindowsFormsApp1/form/PLCADDRESS_Manage.Designer.cs
@@ -35,6 +35,9 @@
this.保存 = new System.Windows.Forms.Button();
this.查询 = new System.Windows.Forms.Button();
this.dataGridView1 = new System.Windows.Forms.DataGridView();
+ this.label1 = new System.Windows.Forms.Label();
+ this.comboBox1 = new System.Windows.Forms.ComboBox();
+ this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.id = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.plcid = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.type = new System.Windows.Forms.DataGridViewComboBoxColumn();
@@ -43,9 +46,6 @@
this.addresstype = new System.Windows.Forms.DataGridViewComboBoxColumn();
this.addresstypelegth = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.remark = new System.Windows.Forms.DataGridViewTextBoxColumn();
- this.label1 = new System.Windows.Forms.Label();
- this.comboBox1 = new System.Windows.Forms.ComboBox();
- this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
this.tableLayoutPanel1.SuspendLayout();
this.SuspendLayout();
@@ -54,9 +54,10 @@
//
this.关闭.Anchor = System.Windows.Forms.AnchorStyles.None;
this.关闭.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.关闭.Location = new System.Drawing.Point(1743, 964);
+ this.关闭.Location = new System.Drawing.Point(1642, 695);
+ this.关闭.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.关闭.Name = "关闭";
- this.关闭.Size = new System.Drawing.Size(92, 41);
+ this.关闭.Size = new System.Drawing.Size(169, 72);
this.关闭.TabIndex = 11;
this.关闭.Text = "关闭";
this.关闭.UseVisualStyleBackColor = true;
@@ -66,9 +67,10 @@
//
this.保存.Anchor = System.Windows.Forms.AnchorStyles.None;
this.保存.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.保存.Location = new System.Drawing.Point(1743, 886);
+ this.保存.Location = new System.Drawing.Point(1642, 532);
+ this.保存.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.保存.Name = "保存";
- this.保存.Size = new System.Drawing.Size(92, 41);
+ this.保存.Size = new System.Drawing.Size(169, 72);
this.保存.TabIndex = 10;
this.保存.Text = "保存";
this.保存.UseVisualStyleBackColor = true;
@@ -78,9 +80,10 @@
//
this.查询.Anchor = System.Windows.Forms.AnchorStyles.None;
this.查询.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.查询.Location = new System.Drawing.Point(1743, 5);
+ this.查询.Location = new System.Drawing.Point(1642, 45);
+ this.查询.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.查询.Name = "查询";
- this.查询.Size = new System.Drawing.Size(92, 41);
+ this.查询.Size = new System.Drawing.Size(169, 72);
this.查询.TabIndex = 9;
this.查询.Text = "查询";
this.查询.UseVisualStyleBackColor = true;
@@ -122,93 +125,24 @@
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dataGridView1.DefaultCellStyle = dataGridViewCellStyle3;
- this.dataGridView1.Location = new System.Drawing.Point(3, 54);
+ this.dataGridView1.Location = new System.Drawing.Point(6, 167);
+ this.dataGridView1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.RowHeadersWidth = 72;
this.tableLayoutPanel1.SetRowSpan(this.dataGridView1, 3);
this.dataGridView1.RowTemplate.Height = 23;
- this.dataGridView1.Size = new System.Drawing.Size(1689, 960);
+ this.dataGridView1.Size = new System.Drawing.Size(1624, 642);
this.dataGridView1.TabIndex = 8;
//
- // id
- //
- this.id.DataPropertyName = "id";
- this.id.HeaderText = "序号";
- this.id.MinimumWidth = 9;
- this.id.Name = "id";
- this.id.ReadOnly = true;
- this.id.Width = 175;
- //
- // plcid
- //
- this.plcid.DataPropertyName = "plcid";
- this.plcid.HeaderText = "所属PLC";
- this.plcid.MinimumWidth = 9;
- this.plcid.Name = "plcid";
- this.plcid.Width = 175;
- //
- // type
- //
- this.type.DataPropertyName = "type";
- this.type.HeaderText = "读写类型";
- this.type.MinimumWidth = 9;
- this.type.Name = "type";
- this.type.Resizable = System.Windows.Forms.DataGridViewTriState.True;
- this.type.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic;
- this.type.Width = 175;
- //
- // dbaddress
- //
- this.dbaddress.DataPropertyName = "dbaddress";
- this.dbaddress.HeaderText = "DB块地址";
- this.dbaddress.MinimumWidth = 9;
- this.dbaddress.Name = "dbaddress";
- this.dbaddress.Width = 175;
- //
- // addressoffset
- //
- this.addressoffset.DataPropertyName = "addressoffset";
- this.addressoffset.HeaderText = "DB地址";
- this.addressoffset.MinimumWidth = 9;
- this.addressoffset.Name = "addressoffset";
- this.addressoffset.Width = 175;
- //
- // addresstype
- //
- this.addresstype.DataPropertyName = "addresstype";
- this.addresstype.HeaderText = "数据类型";
- this.addresstype.MinimumWidth = 9;
- this.addresstype.Name = "addresstype";
- this.addresstype.Resizable = System.Windows.Forms.DataGridViewTriState.True;
- this.addresstype.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic;
- this.addresstype.Width = 175;
- //
- // addresstypelegth
- //
- this.addresstypelegth.DataPropertyName = "addresstypelegth";
- this.addresstypelegth.HeaderText = "字节长度";
- this.addresstypelegth.MinimumWidth = 9;
- this.addresstypelegth.Name = "addresstypelegth";
- this.addresstypelegth.Width = 175;
- //
- // remark
- //
- this.remark.DataPropertyName = "remark";
- this.remark.HeaderText = "注释";
- this.remark.MinimumWidth = 9;
- this.remark.Name = "remark";
- this.remark.ReadOnly = true;
- this.remark.Width = 175;
- //
// label1
//
this.label1.Anchor = System.Windows.Forms.AnchorStyles.Left;
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("宋体", 14.14286F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.label1.Location = new System.Drawing.Point(2, 16);
- this.label1.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+ this.label1.Location = new System.Drawing.Point(4, 47);
+ this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label1.Name = "label1";
- this.label1.Size = new System.Drawing.Size(229, 19);
+ this.label1.Size = new System.Drawing.Size(253, 68);
this.label1.TabIndex = 12;
this.label1.Text = "选择需要编辑的PLC编号:";
//
@@ -217,42 +151,114 @@
this.comboBox1.Anchor = System.Windows.Forms.AnchorStyles.Left;
this.comboBox1.Font = new System.Drawing.Font("宋体", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.comboBox1.FormattingEnabled = true;
- this.comboBox1.Location = new System.Drawing.Point(286, 12);
- this.comboBox1.Margin = new System.Windows.Forms.Padding(2);
+ this.comboBox1.Location = new System.Drawing.Point(278, 60);
+ this.comboBox1.Margin = new System.Windows.Forms.Padding(4);
this.comboBox1.Name = "comboBox1";
- this.comboBox1.Size = new System.Drawing.Size(225, 27);
+ this.comboBox1.Size = new System.Drawing.Size(409, 41);
this.comboBox1.TabIndex = 13;
//
// tableLayoutPanel1
//
this.tableLayoutPanel1.ColumnCount = 3;
- this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 15.07431F));
- this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 74.89384F));
- this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 10F));
+ this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 15.07911F));
+ this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 74.9177F));
+ this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 10.00319F));
this.tableLayoutPanel1.Controls.Add(this.comboBox1, 1, 0);
this.tableLayoutPanel1.Controls.Add(this.dataGridView1, 0, 1);
this.tableLayoutPanel1.Controls.Add(this.关闭, 2, 3);
this.tableLayoutPanel1.Controls.Add(this.label1, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.保存, 2, 2);
this.tableLayoutPanel1.Controls.Add(this.查询, 2, 0);
- this.tableLayoutPanel1.Location = new System.Drawing.Point(8, 12);
+ this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
+ this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 4;
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 5.930233F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 94.06977F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 93F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 63F));
- this.tableLayoutPanel1.Size = new System.Drawing.Size(1884, 1017);
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(1818, 814);
this.tableLayoutPanel1.TabIndex = 14;
//
+ // id
+ //
+ this.id.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.id.DataPropertyName = "id";
+ this.id.HeaderText = "序号";
+ this.id.MinimumWidth = 9;
+ this.id.Name = "id";
+ this.id.ReadOnly = true;
+ //
+ // plcid
+ //
+ this.plcid.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.plcid.DataPropertyName = "plcid";
+ this.plcid.HeaderText = "所属PLC";
+ this.plcid.MinimumWidth = 9;
+ this.plcid.Name = "plcid";
+ //
+ // type
+ //
+ this.type.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.type.DataPropertyName = "type";
+ this.type.HeaderText = "读写类型";
+ this.type.MinimumWidth = 9;
+ this.type.Name = "type";
+ this.type.Resizable = System.Windows.Forms.DataGridViewTriState.True;
+ this.type.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic;
+ //
+ // dbaddress
+ //
+ this.dbaddress.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.dbaddress.DataPropertyName = "dbaddress";
+ this.dbaddress.HeaderText = "DB块地址";
+ this.dbaddress.MinimumWidth = 9;
+ this.dbaddress.Name = "dbaddress";
+ //
+ // addressoffset
+ //
+ this.addressoffset.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.addressoffset.DataPropertyName = "addressoffset";
+ this.addressoffset.HeaderText = "DB地址";
+ this.addressoffset.MinimumWidth = 9;
+ this.addressoffset.Name = "addressoffset";
+ //
+ // addresstype
+ //
+ this.addresstype.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.addresstype.DataPropertyName = "addresstype";
+ this.addresstype.HeaderText = "数据类型";
+ this.addresstype.MinimumWidth = 9;
+ this.addresstype.Name = "addresstype";
+ this.addresstype.Resizable = System.Windows.Forms.DataGridViewTriState.True;
+ this.addresstype.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic;
+ //
+ // addresstypelegth
+ //
+ this.addresstypelegth.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.addresstypelegth.DataPropertyName = "addresstypelegth";
+ this.addresstypelegth.HeaderText = "字节长度";
+ this.addresstypelegth.MinimumWidth = 9;
+ this.addresstypelegth.Name = "addresstypelegth";
+ //
+ // remark
+ //
+ this.remark.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.remark.DataPropertyName = "remark";
+ this.remark.HeaderText = "注释";
+ this.remark.MinimumWidth = 9;
+ this.remark.Name = "remark";
+ this.remark.ReadOnly = true;
+ //
// PLCADDRESS_Manage
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1904, 1041);
+ this.ClientSize = new System.Drawing.Size(1818, 814);
this.Controls.Add(this.tableLayoutPanel1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
- this.Margin = new System.Windows.Forms.Padding(2);
+ this.Margin = new System.Windows.Forms.Padding(4);
this.Name = "PLCADDRESS_Manage";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "PLCADDRESS_Manage";
@@ -272,6 +278,7 @@
private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.ComboBox comboBox1;
+ private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.DataGridViewTextBoxColumn id;
private System.Windows.Forms.DataGridViewTextBoxColumn plcid;
private System.Windows.Forms.DataGridViewComboBoxColumn type;
@@ -280,6 +287,5 @@
private System.Windows.Forms.DataGridViewComboBoxColumn addresstype;
private System.Windows.Forms.DataGridViewTextBoxColumn addresstypelegth;
private System.Windows.Forms.DataGridViewTextBoxColumn remark;
- private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
}
}
\ No newline at end of file
diff --git a/WindowsFormsApp1/form/PLC_Manage.Designer.cs b/WindowsFormsApp1/form/PLC_Manage.Designer.cs
index 36f378e..9e119bc 100644
--- a/WindowsFormsApp1/form/PLC_Manage.Designer.cs
+++ b/WindowsFormsApp1/form/PLC_Manage.Designer.cs
@@ -47,9 +47,10 @@
//
this.关闭.Anchor = System.Windows.Forms.AnchorStyles.None;
this.关闭.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.关闭.Location = new System.Drawing.Point(1743, 955);
+ this.关闭.Location = new System.Drawing.Point(1380, 675);
+ this.关闭.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.关闭.Name = "关闭";
- this.关闭.Size = new System.Drawing.Size(92, 41);
+ this.关闭.Size = new System.Drawing.Size(141, 72);
this.关闭.TabIndex = 7;
this.关闭.Text = "关闭";
this.关闭.UseVisualStyleBackColor = true;
@@ -59,9 +60,10 @@
//
this.保存.Anchor = System.Windows.Forms.AnchorStyles.None;
this.保存.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.保存.Location = new System.Drawing.Point(1743, 866);
+ this.保存.Location = new System.Drawing.Point(1380, 517);
+ this.保存.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.保存.Name = "保存";
- this.保存.Size = new System.Drawing.Size(92, 41);
+ this.保存.Size = new System.Drawing.Size(141, 72);
this.保存.TabIndex = 6;
this.保存.Text = "保存";
this.保存.UseVisualStyleBackColor = true;
@@ -71,9 +73,10 @@
//
this.查询.Anchor = System.Windows.Forms.AnchorStyles.None;
this.查询.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.查询.Location = new System.Drawing.Point(1743, 22);
+ this.查询.Location = new System.Drawing.Point(1380, 43);
+ this.查询.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.查询.Name = "查询";
- this.查询.Size = new System.Drawing.Size(92, 41);
+ this.查询.Size = new System.Drawing.Size(141, 72);
this.查询.TabIndex = 5;
this.查询.Text = "查询";
this.查询.UseVisualStyleBackColor = true;
@@ -109,12 +112,13 @@
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dataGridView1.DefaultCellStyle = dataGridViewCellStyle3;
- this.dataGridView1.Location = new System.Drawing.Point(3, 3);
+ this.dataGridView1.Location = new System.Drawing.Point(6, 5);
+ this.dataGridView1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.RowHeadersWidth = 72;
this.tableLayoutPanel1.SetRowSpan(this.dataGridView1, 4);
this.dataGridView1.RowTemplate.Height = 23;
- this.dataGridView1.Size = new System.Drawing.Size(1689, 1015);
+ this.dataGridView1.Size = new System.Drawing.Size(1362, 780);
this.dataGridView1.TabIndex = 4;
//
// tableLayoutPanel1
@@ -126,52 +130,54 @@
this.tableLayoutPanel1.Controls.Add(this.dataGridView1, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.保存, 1, 2);
this.tableLayoutPanel1.Controls.Add(this.查询, 1, 0);
- this.tableLayoutPanel1.Location = new System.Drawing.Point(8, 8);
+ this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
+ this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 4;
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 10.20179F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 89.7982F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 87F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 90F));
- this.tableLayoutPanel1.Size = new System.Drawing.Size(1884, 1021);
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(1527, 790);
this.tableLayoutPanel1.TabIndex = 8;
//
// id
//
+ this.id.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.id.DataPropertyName = "id";
this.id.HeaderText = "序号";
this.id.MinimumWidth = 9;
this.id.Name = "id";
this.id.ReadOnly = true;
- this.id.Width = 175;
//
// plcip
//
+ this.plcip.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.plcip.DataPropertyName = "plcip";
this.plcip.HeaderText = "IP地址";
this.plcip.MinimumWidth = 9;
this.plcip.Name = "plcip";
this.plcip.ReadOnly = true;
- this.plcip.Width = 175;
//
// timeout
//
+ this.timeout.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.timeout.DataPropertyName = "timeout";
this.timeout.HeaderText = "超时时间";
this.timeout.MinimumWidth = 9;
this.timeout.Name = "timeout";
this.timeout.Resizable = System.Windows.Forms.DataGridViewTriState.True;
this.timeout.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
- this.timeout.Width = 175;
//
// PLC_Manage
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1904, 1041);
+ this.ClientSize = new System.Drawing.Size(1527, 790);
this.Controls.Add(this.tableLayoutPanel1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
- this.Margin = new System.Windows.Forms.Padding(2);
+ this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.Name = "PLC_Manage";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "PLC_Manage";
diff --git a/WindowsFormsApp1/form/SerialPort_Manage.Designer.cs b/WindowsFormsApp1/form/SerialPort_Manage.Designer.cs
new file mode 100644
index 0000000..aaa2350
--- /dev/null
+++ b/WindowsFormsApp1/form/SerialPort_Manage.Designer.cs
@@ -0,0 +1,254 @@
+namespace WindowsFormsApp1
+{
+ partial class SerialPort_Manage
+ {
+ ///
+ /// Required designer variable.
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// Clean up any resources being used.
+ ///
+ /// true if managed resources should be disposed; otherwise, false.
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region Windows Form Designer generated code
+
+ ///
+ /// Required method for Designer support - do not modify
+ /// the contents of this method with the code editor.
+ ///
+ private void InitializeComponent()
+ {
+ System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
+ System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
+ System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
+ this.保存 = new System.Windows.Forms.Button();
+ this.查询 = new System.Windows.Forms.Button();
+ this.dataGridView1 = new System.Windows.Forms.DataGridView();
+ this.关闭 = new System.Windows.Forms.Button();
+ this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
+ this.id = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.name = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.portName = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.baudRate = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.parity = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.dataBits = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.enable = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ this.reamrk = new System.Windows.Forms.DataGridViewTextBoxColumn();
+ ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
+ this.tableLayoutPanel1.SuspendLayout();
+ this.SuspendLayout();
+ //
+ // 保存
+ //
+ this.保存.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.保存.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.保存.Location = new System.Drawing.Point(1488, 528);
+ this.保存.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
+ this.保存.Name = "保存";
+ this.保存.Size = new System.Drawing.Size(153, 56);
+ this.保存.TabIndex = 1;
+ this.保存.Text = "保存";
+ this.保存.UseVisualStyleBackColor = true;
+ this.保存.Click += new System.EventHandler(this.保存_Click);
+ //
+ // 查询
+ //
+ this.查询.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.查询.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.查询.Location = new System.Drawing.Point(1488, 51);
+ this.查询.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
+ this.查询.Name = "查询";
+ this.查询.Size = new System.Drawing.Size(153, 56);
+ this.查询.TabIndex = 3;
+ this.查询.Text = "查询";
+ this.查询.UseVisualStyleBackColor = true;
+ this.查询.Click += new System.EventHandler(this.查询_Click);
+ //
+ // dataGridView1
+ //
+ this.dataGridView1.AllowUserToAddRows = false;
+ this.dataGridView1.AllowUserToDeleteRows = false;
+ dataGridViewCellStyle1.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.dataGridView1.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle1;
+ dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
+ dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Control;
+ dataGridViewCellStyle2.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText;
+ dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+ dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+ dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+ this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle2;
+ this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
+ this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+ this.id,
+ this.name,
+ this.portName,
+ this.baudRate,
+ this.parity,
+ this.dataBits,
+ this.enable,
+ this.reamrk});
+ dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
+ dataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Window;
+ dataGridViewCellStyle3.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ dataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.ControlText;
+ dataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+ dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+ dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
+ this.dataGridView1.DefaultCellStyle = dataGridViewCellStyle3;
+ this.dataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.dataGridView1.Location = new System.Drawing.Point(6, 5);
+ this.dataGridView1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
+ this.dataGridView1.Name = "dataGridView1";
+ this.dataGridView1.RowHeadersWidth = 72;
+ this.tableLayoutPanel1.SetRowSpan(this.dataGridView1, 4);
+ this.dataGridView1.RowTemplate.Height = 23;
+ this.dataGridView1.Size = new System.Drawing.Size(1470, 785);
+ this.dataGridView1.TabIndex = 0;
+ //
+ // 关闭
+ //
+ this.关闭.Anchor = System.Windows.Forms.AnchorStyles.None;
+ this.关闭.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+ this.关闭.Location = new System.Drawing.Point(1488, 687);
+ this.关闭.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
+ this.关闭.Name = "关闭";
+ this.关闭.Size = new System.Drawing.Size(153, 56);
+ this.关闭.TabIndex = 2;
+ this.关闭.Text = "关闭";
+ this.关闭.UseVisualStyleBackColor = true;
+ this.关闭.Click += new System.EventHandler(this.关闭_Click);
+ //
+ // tableLayoutPanel1
+ //
+ this.tableLayoutPanel1.ColumnCount = 2;
+ this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 90F));
+ this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 10F));
+ this.tableLayoutPanel1.Controls.Add(this.dataGridView1, 0, 0);
+ this.tableLayoutPanel1.Controls.Add(this.查询, 1, 0);
+ this.tableLayoutPanel1.Controls.Add(this.关闭, 1, 3);
+ this.tableLayoutPanel1.Controls.Add(this.保存, 1, 2);
+ this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
+ this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
+ this.tableLayoutPanel1.Name = "tableLayoutPanel1";
+ this.tableLayoutPanel1.RowCount = 4;
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(1647, 795);
+ this.tableLayoutPanel1.TabIndex = 4;
+ //
+ // id
+ //
+ this.id.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.id.DataPropertyName = "id";
+ this.id.HeaderText = "序号";
+ this.id.MinimumWidth = 9;
+ this.id.Name = "id";
+ this.id.ReadOnly = true;
+ //
+ // name
+ //
+ this.name.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.name.DataPropertyName = "name";
+ this.name.HeaderText = "名称";
+ this.name.MinimumWidth = 9;
+ this.name.Name = "name";
+ this.name.ReadOnly = true;
+ //
+ // portName
+ //
+ this.portName.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.portName.DataPropertyName = "portName";
+ this.portName.HeaderText = "COM口";
+ this.portName.MinimumWidth = 9;
+ this.portName.Name = "portName";
+ this.portName.ReadOnly = true;
+ //
+ // baudRate
+ //
+ this.baudRate.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.baudRate.DataPropertyName = "baudRate";
+ this.baudRate.HeaderText = "波特率";
+ this.baudRate.MinimumWidth = 9;
+ this.baudRate.Name = "baudRate";
+ //
+ // parity
+ //
+ this.parity.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.parity.DataPropertyName = "parity";
+ this.parity.HeaderText = "奇偶校验位";
+ this.parity.MinimumWidth = 9;
+ this.parity.Name = "parity";
+ //
+ // dataBits
+ //
+ this.dataBits.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.dataBits.DataPropertyName = "dataBits";
+ this.dataBits.HeaderText = "数据位";
+ this.dataBits.MinimumWidth = 9;
+ this.dataBits.Name = "dataBits";
+ //
+ // enable
+ //
+ this.enable.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.enable.DataPropertyName = "enable";
+ this.enable.HeaderText = "是否启用";
+ this.enable.MinimumWidth = 9;
+ this.enable.Name = "enable";
+ this.enable.Resizable = System.Windows.Forms.DataGridViewTriState.True;
+ //
+ // reamrk
+ //
+ this.reamrk.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+ this.reamrk.DataPropertyName = "reamrk";
+ this.reamrk.HeaderText = "备注";
+ this.reamrk.MinimumWidth = 9;
+ this.reamrk.Name = "reamrk";
+ //
+ // SerialPort_Manage
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(1647, 795);
+ this.Controls.Add(this.tableLayoutPanel1);
+ this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+ this.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
+ this.Name = "SerialPort_Manage";
+ this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
+ this.Text = "SerialPort_Manage";
+ this.Load += new System.EventHandler(this.MES_URL_Load);
+ ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
+ this.tableLayoutPanel1.ResumeLayout(false);
+ this.ResumeLayout(false);
+
+ }
+
+ #endregion
+ private System.Windows.Forms.Button 保存;
+ private System.Windows.Forms.Button 查询;
+ private System.Windows.Forms.DataGridView dataGridView1;
+ private System.Windows.Forms.Button 关闭;
+ private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
+ private System.Windows.Forms.DataGridViewTextBoxColumn id;
+ private System.Windows.Forms.DataGridViewTextBoxColumn name;
+ private System.Windows.Forms.DataGridViewTextBoxColumn portName;
+ private System.Windows.Forms.DataGridViewTextBoxColumn baudRate;
+ private System.Windows.Forms.DataGridViewTextBoxColumn parity;
+ private System.Windows.Forms.DataGridViewTextBoxColumn dataBits;
+ private System.Windows.Forms.DataGridViewTextBoxColumn enable;
+ private System.Windows.Forms.DataGridViewTextBoxColumn reamrk;
+ }
+}
\ No newline at end of file
diff --git a/WindowsFormsApp1/form/SerialPort_Manage.cs b/WindowsFormsApp1/form/SerialPort_Manage.cs
new file mode 100644
index 0000000..a80396e
--- /dev/null
+++ b/WindowsFormsApp1/form/SerialPort_Manage.cs
@@ -0,0 +1,79 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using WindowsFormsApp1.db;
+using WindowsFormsApp1.mod;
+using WindowsFormsApp1.mod.database;
+
+namespace WindowsFormsApp1
+{
+ public partial class SerialPort_Manage : Form
+ {
+ public SerialPort_Manage()
+ {
+ InitializeComponent();
+ }
+
+ private void MES_URL_Load(object sender, EventArgs e)
+ {
+ dataGridView1.AutoGenerateColumns = false;
+ GetInfo();
+ }
+
+ private void 保存_Click(object sender, EventArgs e)
+ {
+ try
+ {
+ SQLiteHelper sQLiteHelper = new db.SQLiteHelper();
+ var result = sQLiteHelper.UpdateAll((List)dataGridView1.DataSource);
+ if (result.Success)
+ {
+ MessageBox.Show("更新成功");
+ GetInfo();
+ }
+ else
+ {
+ MessageBox.Show("更新失败");
+ }
+ }
+ catch (Exception ex)
+ {
+ MessageBox.Show($"更新失败,错误原因{ex.Message}");
+ }
+ }
+
+ private void 关闭_Click(object sender, EventArgs e)
+ {
+ this.Close();
+ }
+
+ private void 查询_Click(object sender, EventArgs e)
+ {
+ GetInfo();
+ }
+
+ public void GetInfo()
+ {
+ try
+ {
+ SQLiteHelper sQLiteHelper = new db.SQLiteHelper();
+ var result = sQLiteHelper.QueryAll();
+ if (result.Success)
+ {
+ dataGridView1.DataSource = null;
+ dataGridView1.DataSource = result.Data;
+ dataGridView1.Refresh();
+ }
+ }
+ catch (Exception ex)
+ {
+ }
+ }
+ }
+}
diff --git a/WindowsFormsApp1/form/SerialPort_Manage.resx b/WindowsFormsApp1/form/SerialPort_Manage.resx
new file mode 100644
index 0000000..444a170
--- /dev/null
+++ b/WindowsFormsApp1/form/SerialPort_Manage.resx
@@ -0,0 +1,144 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ True
+
+
+ True
+
+
+ True
+
+
+ True
+
+
+ True
+
+
+ True
+
+
+ True
+
+
+ True
+
+
\ No newline at end of file
diff --git a/WindowsFormsApp1/form/USER_Manage.Designer.cs b/WindowsFormsApp1/form/USER_Manage.Designer.cs
index ffa3046..fbfea84 100644
--- a/WindowsFormsApp1/form/USER_Manage.Designer.cs
+++ b/WindowsFormsApp1/form/USER_Manage.Designer.cs
@@ -68,21 +68,24 @@
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dataGridView1.DefaultCellStyle = dataGridViewCellStyle3;
- this.dataGridView1.Location = new System.Drawing.Point(3, 3);
+ this.dataGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.dataGridView1.Location = new System.Drawing.Point(6, 5);
+ this.dataGridView1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.dataGridView1.Name = "dataGridView1";
this.dataGridView1.RowHeadersWidth = 72;
this.tableLayoutPanel1.SetRowSpan(this.dataGridView1, 4);
this.dataGridView1.RowTemplate.Height = 23;
- this.dataGridView1.Size = new System.Drawing.Size(1685, 1011);
+ this.dataGridView1.Size = new System.Drawing.Size(1475, 711);
this.dataGridView1.TabIndex = 0;
//
// 查询
//
this.查询.Anchor = System.Windows.Forms.AnchorStyles.None;
this.查询.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.查询.Location = new System.Drawing.Point(1739, 34);
+ this.查询.Location = new System.Drawing.Point(1493, 36);
+ this.查询.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.查询.Name = "查询";
- this.查询.Size = new System.Drawing.Size(92, 41);
+ this.查询.Size = new System.Drawing.Size(154, 72);
this.查询.TabIndex = 1;
this.查询.Text = "查询";
this.查询.UseVisualStyleBackColor = true;
@@ -92,9 +95,10 @@
//
this.保存.Anchor = System.Windows.Forms.AnchorStyles.None;
this.保存.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.保存.Location = new System.Drawing.Point(1739, 861);
+ this.保存.Location = new System.Drawing.Point(1493, 468);
+ this.保存.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.保存.Name = "保存";
- this.保存.Size = new System.Drawing.Size(92, 41);
+ this.保存.Size = new System.Drawing.Size(154, 72);
this.保存.TabIndex = 2;
this.保存.Text = "保存";
this.保存.UseVisualStyleBackColor = true;
@@ -104,9 +108,10 @@
//
this.关闭.Anchor = System.Windows.Forms.AnchorStyles.None;
this.关闭.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
- this.关闭.Location = new System.Drawing.Point(1739, 952);
+ this.关闭.Location = new System.Drawing.Point(1493, 612);
+ this.关闭.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.关闭.Name = "关闭";
- this.关闭.Size = new System.Drawing.Size(92, 41);
+ this.关闭.Size = new System.Drawing.Size(154, 72);
this.关闭.TabIndex = 3;
this.关闭.Text = "关闭";
this.关闭.UseVisualStyleBackColor = true;
@@ -117,53 +122,55 @@
this.tableLayoutPanel1.ColumnCount = 2;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 90F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 10F));
- this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
this.tableLayoutPanel1.Controls.Add(this.关闭, 1, 3);
this.tableLayoutPanel1.Controls.Add(this.dataGridView1, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.保存, 1, 2);
this.tableLayoutPanel1.Controls.Add(this.查询, 1, 0);
- this.tableLayoutPanel1.Location = new System.Drawing.Point(13, 12);
+ this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
+ this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 4;
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 13.08411F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 86.91589F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 94F));
- this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 87F));
- this.tableLayoutPanel1.Size = new System.Drawing.Size(1879, 1017);
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 20F));
+ this.tableLayoutPanel1.Size = new System.Drawing.Size(1653, 721);
this.tableLayoutPanel1.TabIndex = 4;
//
// id
//
+ this.id.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.id.DataPropertyName = "id";
this.id.HeaderText = "序号";
this.id.MinimumWidth = 9;
this.id.Name = "id";
this.id.ReadOnly = true;
- this.id.Width = 175;
//
// username
//
+ this.username.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.username.DataPropertyName = "username";
this.username.HeaderText = "用户名";
this.username.MinimumWidth = 9;
this.username.Name = "username";
- this.username.Width = 175;
//
// password
//
+ this.password.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.password.DataPropertyName = "password";
this.password.HeaderText = "密码";
this.password.MinimumWidth = 9;
this.password.Name = "password";
- this.password.Width = 175;
//
// USER_Manage
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 21F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1904, 1041);
+ this.ClientSize = new System.Drawing.Size(1653, 721);
this.Controls.Add(this.tableLayoutPanel1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+ this.Margin = new System.Windows.Forms.Padding(6, 5, 6, 5);
this.Name = "USER_Manage";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "USER_Manage";
diff --git a/WindowsFormsApp1/mod/database/t_serialport.cs b/WindowsFormsApp1/mod/database/t_serialport.cs
new file mode 100644
index 0000000..0a49d29
--- /dev/null
+++ b/WindowsFormsApp1/mod/database/t_serialport.cs
@@ -0,0 +1,36 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using SQLite;
+
+namespace WindowsFormsApp1.mod.database
+{
+ [Table("serialport")]
+ public class t_serialport
+ {
+ [PrimaryKey, AutoIncrement]
+ public int id { get; set; }
+ public string name { get; set; }
+
+ ///
+ /// COM口
+ ///
+ public string portName { get; set; }
+ ///
+ /// 波特率
+ ///
+ public int baudRate { get; set; }
+ ///
+ /// 奇偶校验
+ ///
+ public string parity { get; set; }
+ ///
+ /// 数据位
+ ///
+ public int dataBits { get; set; }
+ public string reamrk { get; set; }
+ public bool enable { get; set; }
+ }
+}
diff --git a/WindowsFormsApp1/mod/server/otherdata.cs b/WindowsFormsApp1/mod/server/otherdata.cs
index 8e7b040..e3d2532 100644
--- a/WindowsFormsApp1/mod/server/otherdata.cs
+++ b/WindowsFormsApp1/mod/server/otherdata.cs
@@ -11,12 +11,12 @@ namespace WindowsFormsApp1.mod.server
///
/// PLC反馈的机台状态
///
- public plcstatus Plc_Status { get; set; }
+ public int Plc_Status { get; set; }
///
/// PLC反馈的机台报警
///
- public string Plc_ErrorMsg { get; set; }
+ public List Plc_ErrorMsgs { get; set; }
///
/// 文件上传地址