123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158 |
- 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;
- namespace IMCS.UControl
- {
- /// <summary>
- /// 智能生产保障系统
- /// </summary>
- public partial class UserControl6 : UserControl
- {
- public UserControl6()
- {
- InitializeComponent();
- this.Load += UserControl6_Load;
- }
- private void UserControl6_Load(object sender, EventArgs e)
- {
- for (int y = 1; y < 11; y++)
- {
- for (int x = 1; x < 31; x++)
- {
- // this.tableLayoutPanel1.GetControlFromPosition
- Label lb = this.tableLayoutPanel1.GetControlFromPosition(x, y) as Label;
- lb.Text = (y + (x - 1) * 10).ToString();
- lb.Tag = (y + (x - 1) * 10).ToString();
- lb.AutoSize = false;
- lb.Width = 69;
- lb.Height = 30;
- lb.BackColor = System.Drawing.Color.AliceBlue;
- lb.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
- }
- }
- int i = 0;
- for (int y = 5; y < 15; y++)
- {
- for (int x = 18; x < 21; x++)
- {
- i++;
- // this.tableLayoutPanel1.GetControlFromPosition
- Label lb = this.tableLayoutPanel1.GetControlFromPosition(y, x) as Label;
- lb.Text = i.ToString();
- lb.Tag = "xia" + (i).ToString();
- lb.AutoSize = false;
- lb.Width = 69;
- lb.Height = 30;
- lb.BackColor = System.Drawing.Color.AliceBlue;
- lb.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
- }
- }
- this.BackgroundImage = global::IMCS.Properties.Resources.backgroup1;
- this.BackgroundImageLayout = ImageLayout.Stretch;
- this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
- #region 私服舵机
- this.uctl_SiFu.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_SiFu.deviceStateDefaultList.Device_Name = "私服舵机";
- this.uctl_SiFu.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_SiFu.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region AGV上下料站1
- this.uctl_AGV1.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_AGV1.deviceStateDefaultList.Device_Name = "AGV上下料站1";
- this.uctl_AGV1.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_AGV1.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region AGV上下料站2
- this.uctl_AGV2.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_AGV2.deviceStateDefaultList.Device_Name = "AGV上下料站2";
- this.uctl_AGV2.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_AGV2.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 三坐标检测
- this.uctl_SanZuoBiao.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_SanZuoBiao.deviceStateDefaultList.Device_Name = "三坐标检测";
- this.uctl_SanZuoBiao.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_SanZuoBiao.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 激光打标机
- this.uctl_DaBiaoJI.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_DaBiaoJI.deviceStateDefaultList.Device_Name = "激光打标机";
- this.uctl_DaBiaoJI.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_DaBiaoJI.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 上下料站1
- this.uctl_ShangXiaZhan1.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_ShangXiaZhan1.deviceStateDefaultList.Device_Name = "上下料站1";
- this.uctl_ShangXiaZhan1.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_ShangXiaZhan1.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 上下料站2
- this.uctl_ShangXiaZhan2.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_ShangXiaZhan2.deviceStateDefaultList.Device_Name = "上下料站2";
- this.uctl_ShangXiaZhan2.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_ShangXiaZhan2.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 上下料站3
- this.uctl_ShangXiaZhan3.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_ShangXiaZhan3.deviceStateDefaultList.Device_Name = "上下料站3";
- this.uctl_ShangXiaZhan3.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_ShangXiaZhan3.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 上下料站4
- this.uctl_ShangXiaZhan4.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_ShangXiaZhan4.deviceStateDefaultList.Device_Name = "上下料站4";
- this.uctl_ShangXiaZhan4.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_ShangXiaZhan4.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 上下料站5
- this.uctl_ShangXiaZhan5.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_ShangXiaZhan5.deviceStateDefaultList.Device_Name = "上下料站5";
- this.uctl_ShangXiaZhan5.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_ShangXiaZhan5.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- #region 上下料站6
- this.uctl_ShangXiaZhan6.deviceStateDefaultList.Device_ConnectionMes = true;
- this.uctl_ShangXiaZhan6.deviceStateDefaultList.Device_Name = "上下料站6";
- this.uctl_ShangXiaZhan6.deviceStateDefaultList.Device_OnLine = true;
- this.uctl_ShangXiaZhan6.deviceStateDefaultList.Device_Runing = DefaultList.EnumDeviceRunState.RunState_Run;
- #endregion
- }
- }
- }
|