修改料盘信息位5列10行

master
lhiven 2 years ago
parent 146c998d47
commit c99b68e83d

@ -31,10 +31,10 @@
this.components = new System.ComponentModel.Container(); this.components = new System.ComponentModel.Container();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(TrayRecipe));
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = 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(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(TrayRecipe));
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.panel1 = new System.Windows.Forms.Panel(); this.panel1 = new System.Windows.Forms.Panel();
this.panel2 = new System.Windows.Forms.Panel(); this.panel2 = new System.Windows.Forms.Panel();
@ -43,6 +43,10 @@
this.panel3 = new System.Windows.Forms.Panel(); this.panel3 = new System.Windows.Forms.Panel();
this.panelEx1 = new Rs.Controls.PanelEx(); this.panelEx1 = new Rs.Controls.PanelEx();
this.dataGridView1 = new System.Windows.Forms.DataGridView(); this.dataGridView1 = new System.Windows.Forms.DataGridView();
this.Index = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.X = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Y = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Move = new System.Windows.Forms.DataGridViewLinkColumn();
this.panelEx2 = new Rs.Controls.PanelEx(); this.panelEx2 = new Rs.Controls.PanelEx();
this.label1 = new System.Windows.Forms.Label(); this.label1 = new System.Windows.Forms.Label();
this.panel5 = new System.Windows.Forms.Panel(); this.panel5 = new System.Windows.Forms.Panel();
@ -55,10 +59,6 @@
this.timer1 = new System.Windows.Forms.Timer(this.components); this.timer1 = new System.Windows.Forms.Timer(this.components);
this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components); this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components);
this.tsmi_go = new System.Windows.Forms.ToolStripMenuItem(); this.tsmi_go = new System.Windows.Forms.ToolStripMenuItem();
this.Index = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.X = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Y = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Move = new System.Windows.Forms.DataGridViewLinkColumn();
this.tableLayoutPanel1.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout();
this.panel1.SuspendLayout(); this.panel1.SuspendLayout();
this.panel2.SuspendLayout(); this.panel2.SuspendLayout();
@ -121,13 +121,13 @@
// rsTray1 // rsTray1
// //
this.rsTray1.CanDraw = false; this.rsTray1.CanDraw = false;
this.rsTray1.ColumnNum = 10; this.rsTray1.ColumnNum = 5;
this.rsTray1.Dock = System.Windows.Forms.DockStyle.Fill; this.rsTray1.Dock = System.Windows.Forms.DockStyle.Fill;
this.rsTray1.HeadText = null; this.rsTray1.HeadText = null;
this.rsTray1.LeftSpaceWidth = 20; this.rsTray1.LeftSpaceWidth = 20;
this.rsTray1.Location = new System.Drawing.Point(5, 0); this.rsTray1.Location = new System.Drawing.Point(5, 0);
this.rsTray1.Name = "rsTray1"; this.rsTray1.Name = "rsTray1";
this.rsTray1.RowNum = 26; this.rsTray1.RowNum = 10;
this.rsTray1.SelectSlot = null; this.rsTray1.SelectSlot = null;
this.rsTray1.ShowText = true; this.rsTray1.ShowText = true;
this.rsTray1.Size = new System.Drawing.Size(285, 585); this.rsTray1.Size = new System.Drawing.Size(285, 585);
@ -199,6 +199,52 @@
this.dataGridView1.TabIndex = 2; this.dataGridView1.TabIndex = 2;
this.dataGridView1.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellContentClick); this.dataGridView1.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellContentClick);
// //
// Index
//
this.Index.DataPropertyName = "Index";
this.Index.FillWeight = 10F;
this.Index.HeaderText = "IX";
this.Index.Name = "Index";
this.Index.ReadOnly = true;
//
// X
//
this.X.DataPropertyName = "X";
dataGridViewCellStyle2.Format = "0.000";
this.X.DefaultCellStyle = dataGridViewCellStyle2;
this.X.FillWeight = 35F;
this.X.HeaderText = "X";
this.X.Name = "X";
this.X.ReadOnly = true;
//
// Y
//
this.Y.DataPropertyName = "Y";
dataGridViewCellStyle3.Format = "0.000";
this.Y.DefaultCellStyle = dataGridViewCellStyle3;
this.Y.FillWeight = 35F;
this.Y.HeaderText = "Y";
this.Y.Name = "Y";
this.Y.ReadOnly = true;
//
// Move
//
this.Move.ActiveLinkColor = System.Drawing.Color.White;
dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle4.BackColor = System.Drawing.Color.Silver;
dataGridViewCellStyle4.ForeColor = System.Drawing.Color.White;
this.Move.DefaultCellStyle = dataGridViewCellStyle4;
this.Move.FillWeight = 20F;
this.Move.HeaderText = "Move";
this.Move.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline;
this.Move.LinkColor = System.Drawing.Color.Lime;
this.Move.Name = "Move";
this.Move.ReadOnly = true;
this.Move.Text = "Go";
this.Move.TrackVisitedState = false;
this.Move.UseColumnTextForLinkValue = true;
this.Move.VisitedLinkColor = System.Drawing.Color.White;
//
// panelEx2 // panelEx2
// //
this.panelEx2.Controls.Add(this.label1); this.panelEx2.Controls.Add(this.label1);
@ -317,52 +363,6 @@
this.tsmi_go.Text = "Go"; this.tsmi_go.Text = "Go";
this.tsmi_go.Click += new System.EventHandler(this.tsmi_go_Click); this.tsmi_go.Click += new System.EventHandler(this.tsmi_go_Click);
// //
// Index
//
this.Index.DataPropertyName = "Index";
this.Index.FillWeight = 10F;
this.Index.HeaderText = "IX";
this.Index.Name = "Index";
this.Index.ReadOnly = true;
//
// X
//
this.X.DataPropertyName = "X";
dataGridViewCellStyle2.Format = "0.000";
this.X.DefaultCellStyle = dataGridViewCellStyle2;
this.X.FillWeight = 35F;
this.X.HeaderText = "X";
this.X.Name = "X";
this.X.ReadOnly = true;
//
// Y
//
this.Y.DataPropertyName = "Y";
dataGridViewCellStyle3.Format = "0.000";
this.Y.DefaultCellStyle = dataGridViewCellStyle3;
this.Y.FillWeight = 35F;
this.Y.HeaderText = "Y";
this.Y.Name = "Y";
this.Y.ReadOnly = true;
//
// Move
//
this.Move.ActiveLinkColor = System.Drawing.Color.White;
dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
dataGridViewCellStyle4.BackColor = System.Drawing.Color.Silver;
dataGridViewCellStyle4.ForeColor = System.Drawing.Color.White;
this.Move.DefaultCellStyle = dataGridViewCellStyle4;
this.Move.FillWeight = 20F;
this.Move.HeaderText = "Move";
this.Move.LinkBehavior = System.Windows.Forms.LinkBehavior.NeverUnderline;
this.Move.LinkColor = System.Drawing.Color.Lime;
this.Move.Name = "Move";
this.Move.ReadOnly = true;
this.Move.Text = "Go";
this.Move.TrackVisitedState = false;
this.Move.UseColumnTextForLinkValue = true;
this.Move.VisitedLinkColor = System.Drawing.Color.White;
//
// TrayRecipe // TrayRecipe
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);

@ -36,7 +36,7 @@ namespace Rs.MotionPlat
{ {
dataGridView1.AutoGenerateColumns = false; dataGridView1.AutoGenerateColumns = false;
rsTray1.HeadText = m_button.ShowText; rsTray1.HeadText = m_button.ShowText;
trayPosition = TrayPosition.Load(m_button.ShowText); trayPosition = TrayPosition.Load(m_button.ShowText,10,5);
slot_lefttop.Position = trayPosition.LeftTop; slot_lefttop.Position = trayPosition.LeftTop;
slot_leftbottom.Position = trayPosition.LeftBottom; slot_leftbottom.Position = trayPosition.LeftBottom;
slot_rightbottom.Position = trayPosition.RightBottom; slot_rightbottom.Position = trayPosition.RightBottom;
@ -54,8 +54,8 @@ namespace Rs.MotionPlat
if (val == 0) val = 1; if (val == 0) val = 1;
else if (val == 1) val = 0; else if (val == 1) val = 0;
rsTray1.ChangeStatus(1, val); rsTray1.ChangeStatus(1, val);
rsTray1.ChangeStatus(26, val); rsTray1.ChangeStatus(10, val);
rsTray1.ChangeStatus(260, val); rsTray1.ChangeStatus(50, val);
} }
protected void SavePosEvent(object sender, EventArgs e) protected void SavePosEvent(object sender, EventArgs e)
@ -80,7 +80,7 @@ namespace Rs.MotionPlat
trayPosition.LeftBottom = new PointF(slot_leftbottom.PosX, slot_leftbottom.PosY); trayPosition.LeftBottom = new PointF(slot_leftbottom.PosX, slot_leftbottom.PosY);
if (trayLocation == slot_rightbottom) if (trayLocation == slot_rightbottom)
trayPosition.RightBottom = new PointF(slot_rightbottom.PosX, slot_rightbottom.PosY); trayPosition.RightBottom = new PointF(slot_rightbottom.PosX, slot_rightbottom.PosY);
trayPosition.Save(); trayPosition.Save();
} }
private void dataGridView1_CellContentClick(object sender, DataGridViewCellEventArgs e) private void dataGridView1_CellContentClick(object sender, DataGridViewCellEventArgs e)

Loading…
Cancel
Save