From f9f8e587d1e340599f36f5f07505be7978c08eaf Mon Sep 17 00:00:00 2001 From: gongxh Date: Tue, 10 May 2022 15:21:13 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CleanMachine.BLL/CM/IncomingReceipt.cs | 303 +++++++++ CleanMachine.BLL/CM/ShiftCountBLL.cs | 79 +++ CleanMachine.BLL/CleanMachine.BLL.csproj | 6 + CleanMachine.DAL/CM/ShiftCountDAL.cs | 96 +++ CleanMachine.Model/BAS/PlcItem.cs | 4 +- CleanMachine.Model/BAS/PlcItemTypeDesc.cs | 26 + CleanMachine.Model/CM/ShiftCount.cs | 31 + CleanMachineHMI/CleanMachineHMI.csproj | 6 + CleanMachineHMI/DataBase/clearMac.db | Bin 380928 -> 380928 bytes .../FrmUserControl/frmCurrWorkingIrMsg.cs | 3 +- .../FrmUserControl/frmIOMonitor.cs | 164 +++-- .../FrmUserControl/frmMainDetail.Designer.cs | 519 ++++++--------- .../FrmUserControl/frmMainDetail.cs | 592 +++++++----------- .../FrmUserControl/frmMaintenance.cs | 3 +- CleanMachineHMI/FrmUserControl/frmManual.cs | 3 +- .../FrmUserControl/frmMechineCheck.cs | 3 +- .../FrmUserControl/frmPlcAlarmLog.cs | 1 + .../FrmUserControl/frmPlcItemConfig.cs | 8 +- CleanMachineHMI/Utils/GlobalHelper.cs | 19 +- CleanMachineHMI/Utils/PlcOperationHelper.cs | 89 +-- .../frmChild/frmSwitchRunDirection.cs | 3 +- CleanMachineHMI/frmIoMonitorNew.cs | 89 +-- 22 files changed, 1216 insertions(+), 831 deletions(-) create mode 100644 CleanMachine.BLL/CM/IncomingReceipt.cs create mode 100644 CleanMachine.BLL/CM/ShiftCountBLL.cs create mode 100644 CleanMachine.DAL/CM/ShiftCountDAL.cs create mode 100644 CleanMachine.Model/BAS/PlcItemTypeDesc.cs create mode 100644 CleanMachine.Model/CM/ShiftCount.cs diff --git a/CleanMachine.BLL/CM/IncomingReceipt.cs b/CleanMachine.BLL/CM/IncomingReceipt.cs new file mode 100644 index 0000000..3fc3273 --- /dev/null +++ b/CleanMachine.BLL/CM/IncomingReceipt.cs @@ -0,0 +1,303 @@ +using FastReport; +using LeadDataBaseUtility; +using NX_LogUtility; +using System; +using System.Collections.Generic; +using System.Data; +using System.Text; + +namespace CleanMachine.BLL.CM +{ + public class IncomingReceipt + { + + public bool Print(string workingIrCodeMsg, string MacCode, string _reportFolder) + { + try + { + + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】自动打印开始。~~~~~~~~~~~~~~", LogTypeEum.Run); + //string sql = $@" + // SELECT + // * + // FROM + // VW_WORKING_PALLET_MSG + // WHERE + // WORKING_PALLET_CODE = '{woringPalletMsg}' + // AND IR_CODE = '{workingIrCodeMsg}' + // "; + string sql = $@" + SELECT + * + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + "; + DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0]; + if (dt != null && dt.Rows.Count > 0) + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + + string sqlGroup = $@" + SELECT + CONTAMINATION_TYPE_CODE, + CONTAMINATION_DTL_CODE, + SUM(CURRENT_NUMBER) CURRENT_NUMBER + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + GROUP BY + CONTAMINATION_TYPE_CODE, + CONTAMINATION_DTL_CODE + "; + DataTable dtGroup = LeadDbHelperSQLite.Query(sqlGroup).Tables[0]; + + #region 物理污染 + //string sql1 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'PhysicalContamination'"; + //DataTable dt1 = LeadDbHelperSQLite.Query(sql1).Tables[0].Copy(); + + DataRow[] drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'PhysicalContamination'"); + if (drs != null && drs.Length > 0) + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】物理污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + } + else + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】物理污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); + } + DataTable dt1 = new DataTable(); + dt1.Columns.Add("Kind", typeof(string)); + dt1.Columns.Add("Qty", typeof(string)); + foreach (DataRow item in drs) + { + DataRow row = dt1.NewRow(); + row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString(); + row["Qty"] = item["CURRENT_NUMBER"].ToString(); + dt1.Rows.Add(row); + } + dt1.TableName = "Table1"; + #endregion + + #region 化学污染 + //string sql2 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'ChemicalContamination'"; + //DataTable dt2 = LeadDbHelperSQLite.Query(sql2).Tables[0].Copy(); + drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'ChemicalContamination'"); + if (drs != null && drs.Length > 0) + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】化学污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + } + else + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】化学污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); + } + DataTable dt2 = dt1.Clone(); + foreach (DataRow item in drs) + { + DataRow row = dt2.NewRow(); + row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString(); + row["Qty"] = item["CURRENT_NUMBER"].ToString(); + dt2.Rows.Add(row); + } + dt2.TableName = "Table2"; + #endregion + + #region 微生物污染 + //string sql3 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'MicrobiologicalContamination'"; + //DataTable dt3 = LeadDbHelperSQLite.Query(sql3).Tables[0].Copy(); + drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'MicrobiologicalContamination'"); + if (drs != null && drs.Length > 0) + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】微生物污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + } + else + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】微生物污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); + } + DataTable dt3 = dt1.Clone(); + foreach (DataRow item in drs) + { + DataRow row = dt3.NewRow(); + row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString(); + row["Qty"] = item["CURRENT_NUMBER"].ToString(); + dt3.Rows.Add(row); + } + dt3.TableName = "Table3"; + #endregion + + string sql4 = $@" + SELECT + C.SHEET_TYPE_CODE Sheets, + SUM(CASE CLEAN_MODE_CODE WHEN 'SortedCleaned' THEN Qty ELSE 0 END) SortedCleaned, + SUM(CASE CLEAN_MODE_CODE WHEN 'SpecialCleaning' THEN Qty ELSE 0 END) SpecialCleaning, + SUM(CASE CLEAN_MODE_CODE WHEN 'Scrap' THEN Qty ELSE 0 END) Scrap, + SUM(CASE CLEAN_MODE_CODE WHEN 'Others' THEN Qty ELSE 0 END) Others, + IFNULL(C.TotalQty, 0) TotalQty + FROM + ( + SELECT + A.SHEET_TYPE_CODE, + B.CLEAN_MODE_CODE, + B.Qty, + C.TotalQty + FROM + BAS_SHEET_TYPE A LEFT JOIN + ( + SELECT + SHEET_TYPE_CODE, + SUM(CURRENT_NUMBER) TotalQty + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + GROUP BY SHEET_TYPE_CODE) C ON A.SHEET_TYPE_CODE = C.SHEET_TYPE_CODE + LEFT JOIN ( + SELECT + SHEET_TYPE_CODE, + CLEAN_MODE_CODE, + SUM(CURRENT_NUMBER) Qty + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + GROUP BY CLEAN_MODE_CODE,SHEET_TYPE_CODE + ) B ON C.SHEET_TYPE_CODE = B.SHEET_TYPE_CODE + ) C + GROUP BY C.SHEET_TYPE_CODE,C.TotalQty + "; + + DataTable dt4 = LeadDbHelperSQLite.Query(sql4).Tables[0].Copy(); + if (dt4 != null && dt4.Rows.Count > 0) + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】按照板材分类和清洗方式统计的数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + } + else + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】按照板材分类和清洗方式统计的数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); + } + + dt4.TableName = "Table4"; + + + string sql5 = $@" + SELECT + SUM (CURRENT_NUMBER) CleanedSheets, + date (INPUT_TIME) DateAndTime, + USER_NAME Operator + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + GROUP BY + date (INPUT_TIME), + OPERATE_USER_ID, + USER_CODE, + USER_NAME + "; + + DataTable dt5 = LeadDbHelperSQLite.Query(sql5).Tables[0].Copy(); + if (dt5 != null && dt5.Rows.Count > 0) + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】操作员每日作业板材数量的数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + } + else + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】操作员每日作业板材数量的数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); + } + dt5.TableName = "Table5"; + + string userName = dt.Rows[0]["USER_NAME"].ToString(); + DateTime dateMsg = Convert.ToDateTime(dt.Rows[0]["INPUT_TIME"]); + string IRNumber = dt.Rows[0]["IR_CODE"].ToString(); + // string MacCode = Global.MacCode; //GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'CleanMachineName'")[0]["PARAMETER_VALUE"].ToString(); + + string sqlCleanedNum = $@" + SELECT + SUM(CURRENT_NUMBER) CURRENT_NUMBER + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + AND CLEAN_MODE_CODE = 'SortedCleaned' + "; + DataTable dtCleanedNum = LeadDbHelperSQLite.Query(sqlCleanedNum).Tables[0]; + string cleanNum = dtCleanedNum.Rows[0][0].ToString(); + + string sqlPalletNum = $@" + SELECT + DISTINCT WORKING_PALLET_CODE + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + "; + DataTable dtPalletNum = LeadDbHelperSQLite.Query(sqlPalletNum).Tables[0]; + string palletNum = dtPalletNum.Rows.Count.ToString(); + + string sqlScrapNum = $@" + SELECT + SUM(CURRENT_NUMBER) CURRENT_NUMBER + FROM + VW_WORKING_PALLET_MSG + WHERE + IR_CODE = '{workingIrCodeMsg}' + AND CLEAN_MODE_CODE <> 'SortedCleaned' + "; + DataTable dtScrapNum = LeadDbHelperSQLite.Query(sqlScrapNum).Tables[0]; + string scrapNum = dtScrapNum.Rows[0][0].ToString(); + + DataSet dts = new DataSet(); + dts.Tables.Add(dt1); + dts.Tables.Add(dt2); + dts.Tables.Add(dt3); + dts.Tables.Add(dt4); + dts.Tables.Add(dt5); + + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印模板所需要的数据拼装完成!~~~~~~~~~~~~~~", LogTypeEum.Run); + + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】开始加载打印控件类!~~~~~~~~~~~~~~", LogTypeEum.Run); + Report report = new Report(); + string filename = _reportFolder + "CleanMac_IRMsg_PrintMd.frx"; + report.Load(filename); + report.RegisterData(dts); + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类加载完成,数据传入成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + report.SetParameterValue("Parm_CusName", userName); + report.SetParameterValue("Parm_MachineCode", MacCode); + report.SetParameterValue("Parm_IRNumber", IRNumber); + report.SetParameterValue("Parm_RecDate", dateMsg); + report.SetParameterValue("Parm_RecordName", userName); + report.SetParameterValue("Parm_CleanedNum", cleanNum); + report.SetParameterValue("Parm_PalletNumber", palletNum); + report.SetParameterValue("Parm_ScrapNumber", scrapNum); + + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类所需参数设置成功,开始发送打印机数据!~~~~~~~~~~~~~~", LogTypeEum.Run); + report.Prepare(); + report.PrintSettings.ShowDialog = false; + report.Print(); + report.Clear(); + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类发送打印机数据成功!~~~~~~~~~~~~~~", LogTypeEum.Run); + } + else + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); + } + LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】自动打印结束。~~~~~~~~~~~~~~", LogTypeEum.Run); + + + return true; + } + catch (Exception) + { + + return false; + } + + } + + + + + + } +} diff --git a/CleanMachine.BLL/CM/ShiftCountBLL.cs b/CleanMachine.BLL/CM/ShiftCountBLL.cs new file mode 100644 index 0000000..1c29c9c --- /dev/null +++ b/CleanMachine.BLL/CM/ShiftCountBLL.cs @@ -0,0 +1,79 @@ +using CleanMachine.DAL.CM; +using System; +using System.Collections.Generic; +using System.Text; + +namespace CleanMachine.BLL.CM +{ + /// + /// + /// + public class ShiftCountBLL + { + + public ShiftCountBLL() + { + + } + + /// + /// 存在 + /// + public bool Exists(DateTime DateTime) + { + return new ShiftCountDAL().Exists(DateTime); + } + + /// + /// 添加一个数据 + /// + public bool Add(CleanMachine.Model.CM.ShiftCount model) + { + return new ShiftCountDAL().Add(model); + } + + /// + /// 更新一个数据 + /// + public bool Update(CleanMachine.Model.CM.ShiftCount model) + { + return new ShiftCountDAL().Update(model); + } + + + /// + /// 删除一个数据 + /// + public bool Delete(string strWhere, object Params = null) + { + return new ShiftCountDAL().Delete(strWhere, Params); + } + + /// + /// 删除一个数据 + /// + public bool Delete(DateTime DateTime) + { + return new ShiftCountDAL().Delete(DateTime); + } + + /// + /// 获得数据列表 + /// + public IEnumerable GetList(string strWhere, object Params = null) + { + return new ShiftCountDAL().GetList(strWhere, Params); + } + + + + /// + /// 查询数据 + /// + // public IEnumerable GetModelList(RuleGroup rule) + // { + // return new ShiftCountDAL().GetModelList(rule); + // } + } +} + diff --git a/CleanMachine.BLL/CleanMachine.BLL.csproj b/CleanMachine.BLL/CleanMachine.BLL.csproj index 98c8765..d17533b 100644 --- a/CleanMachine.BLL/CleanMachine.BLL.csproj +++ b/CleanMachine.BLL/CleanMachine.BLL.csproj @@ -9,4 +9,10 @@ + + + ..\public\FastReport.dll + + + diff --git a/CleanMachine.DAL/CM/ShiftCountDAL.cs b/CleanMachine.DAL/CM/ShiftCountDAL.cs new file mode 100644 index 0000000..9effd75 --- /dev/null +++ b/CleanMachine.DAL/CM/ShiftCountDAL.cs @@ -0,0 +1,96 @@ +using LeadDataBaseUtility; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace CleanMachine.DAL.CM +{ + public class ShiftCountDAL + { + public ShiftCountDAL() + { + + } + #region 一般方法 + /// + /// 存在 + /// + public bool Exists(DateTime DateTime) + { + string strSql = @"SELECT count(1) from CM_SHIFT_COUNT WHERE DateTime=@DateTime "; + return LeadDbHelperSQLite.ExecuteScalar(strSql, new { DateTime }) > 0; + } + + /// + /// 添加一个数据 + /// + public bool Add(CleanMachine.Model.CM.ShiftCount model) + { + string strSql = $@"INSERT INTO CM_SHIFT_COUNT + (DateTime,count) + values + (@DateTime,@Count) "; + return LeadDbHelperSQLite.Execute(strSql, model) > 0; + } + + /// + /// 更新一个数据 + /// + public bool Update(CleanMachine.Model.CM.ShiftCount model) + { + string strSql = $@"UPDATE CM_SHIFT_COUNT SET + count=@Count + WHERE DateTime=@DateTime "; + return LeadDbHelperSQLite.Execute(strSql, model) > 0; + } + + + /// + /// 删除一个数据 + /// + public bool Delete(string strWhere, object Params = null) + { + string strSql = $@"DELETE FROM CM_SHIFT_COUNT "; + if (strWhere.Trim() != "") + { + strSql += $" WHERE {strWhere}"; + } + return LeadDbHelperSQLite.Execute(strSql, Params) > 0; + } + + /// + /// 删除一个数据 + /// + public bool Delete(DateTime DateTime) + { + return this.Delete("DateTime=@DateTime ", new { DateTime }); + } + + /// + /// 获得数据列表 + /// + public IEnumerable GetList(string strWhere, object Params = null) + { + string strSql = $@"SELECT * FROM CM_SHIFT_COUNT "; + if (strWhere.Trim() != "") + { + strSql += $" WHERE {strWhere}"; + } + return LeadDbHelperSQLite.Query (strSql, Params); + } + + /// + /// 获取一个对象 + /// + public CleanMachine.Model.CM.ShiftCount GetModel(DateTime DateTime) + { + return this.GetList("DateTime=@DateTime", new { DateTime }).FirstOrDefault(); + } + #endregion + + + + + } +} diff --git a/CleanMachine.Model/BAS/PlcItem.cs b/CleanMachine.Model/BAS/PlcItem.cs index 7520e86..f934ecf 100644 --- a/CleanMachine.Model/BAS/PlcItem.cs +++ b/CleanMachine.Model/BAS/PlcItem.cs @@ -18,7 +18,7 @@ namespace CleanMachine.Model.BAS private string plcItemCode; private string plcItemName; private int plcItemType; - private int plcItemDataType; + private PlcItemTypeDesc plcItemDataType; private int plcItemDataLength; private string plcItemPriAddress; private string plcItemModbusAddress; @@ -76,7 +76,7 @@ namespace CleanMachine.Model.BAS /// /// /// - public int PlcItemDataType + public PlcItemTypeDesc PlcItemDataType { get { return this.plcItemDataType; } set { this.plcItemDataType=value;} diff --git a/CleanMachine.Model/BAS/PlcItemTypeDesc.cs b/CleanMachine.Model/BAS/PlcItemTypeDesc.cs new file mode 100644 index 0000000..80ef0d4 --- /dev/null +++ b/CleanMachine.Model/BAS/PlcItemTypeDesc.cs @@ -0,0 +1,26 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace CleanMachine.Model.BAS +{ + public enum PlcItemTypeDesc + { + /// + /// M 类型布尔变量 + /// + M, + /// + /// D 类型整数变量 + /// + D, + /// + /// X 类型布尔变量 + /// + X, + /// + /// Y 类型布尔变量 + /// + Y + } +} diff --git a/CleanMachine.Model/CM/ShiftCount.cs b/CleanMachine.Model/CM/ShiftCount.cs new file mode 100644 index 0000000..a8a9631 --- /dev/null +++ b/CleanMachine.Model/CM/ShiftCount.cs @@ -0,0 +1,31 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace CleanMachine.Model.CM +{ + public class ShiftCount + { + private DateTime dateTime; + private int count; + + /// + /// + /// + public DateTime DateTime + { + get { return this.dateTime; } + set { this.dateTime = value; } + } + + /// + /// + /// + public int Count + { + get { return this.count; } + set { this.count = value; } + } + + } +} diff --git a/CleanMachineHMI/CleanMachineHMI.csproj b/CleanMachineHMI/CleanMachineHMI.csproj index e42446e..29732ea 100644 --- a/CleanMachineHMI/CleanMachineHMI.csproj +++ b/CleanMachineHMI/CleanMachineHMI.csproj @@ -70,6 +70,12 @@ SettingsSingleFileGenerator Settings.Designer.cs + + PreserveNewest + + + PreserveNewest + diff --git a/CleanMachineHMI/DataBase/clearMac.db b/CleanMachineHMI/DataBase/clearMac.db index 4c51a0f7618145441c439a1b5f31d60577ba9ed2..a3c505ac66152669a12aec9c32cc77d1c8b7c50c 100644 GIT binary patch delta 560 zcmZozAl|S*e1f##31-1z=G9Hj-O=e(c(q`b|=a|f?%cRYJo-cs!Jp^u^sKC#( zUHcNF1v3k09nq6E|ld-Y5 zBrz!`)!8>b*u&E;B;MIS)Gq{;XY3s0>KNjx5aQ_MxKoCYn zXWhVT#97I9m936VoORB2hYif0%pjQc^LeGbk!Eaxw~w z3JP*?a2j(Oa{wh77=kl0(@LB{egU%-z)Yt072BD&uh`BKabh{+17?9~4_H{Yvrb_B GZ4UszdYcpg delta 674 zcmZozAl|S*e1f!K9|HqJED$pTu`m!nn5bjS*taoZzr3L_kZS_Ora){C#AZNj1jH^t zYzxHpK7S3QuNrP-Nr%#?QpdxLL`dAW ztjS#boMjx7Idz$|`Oj~js36L;UHcNF1#?21ZZNyJr6pr`X-Q&IPAYa|v5Q7J2e~?i zxGID=I{CONC}CH$J@FFbSte#)F3staZ!q4g=Ky+>p;0W9UEI@?u~8jjsk3jqPhxRN zKw?QrPO4vNF3eAc2F3?JKskM4S-f buttons = new Dictionary(); + + + private CircleButton findeControl(PlcItem item) { - PlcItem item = sender as PlcItem; - BeginInvoke(new Action(() => + var controlname = item.PlcItemDataType == PlcItemTypeDesc.X ? "cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0') : + "cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'); + var controls = this.Controls.Find(controlname, true); + return controls.Count() > 0 ? controls[0] as CircleButton : null; + + } + + private void Show_X_Y_Status(IEnumerable items) + { + + + foreach (var item in items) { - if (item.PlcItemDataType == 2) + if (!buttons.TryGetValue(item, out var btn)) { - if (this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) - { - CircleButton ctn = this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as CircleButton; - if (string.IsNullOrEmpty(item.PlcItemValue)) - { - ctn.BackColor = Color.FromArgb(191, 219, 255); - } - else if (bool.Parse(item.PlcItemValue.ToString())) - { - ctn.BackColor = Color.Lime; - } - else - { - ctn.BackColor = Color.Red; - } - } + btn = findeControl(item); + buttons.Add(item, btn); + } + if (string.IsNullOrEmpty(item.PlcItemValue)) + { + btn.BackColor = Color.FromArgb(191, 219, 255); + } + else if (bool.Parse(item.PlcItemValue.ToString())) + { + btn.BackColor = Color.Lime; } else { - if (this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) - { - CircleButton ctn = this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as CircleButton; - if (string.IsNullOrEmpty(item.PlcItemValue)) - { - ctn.BackColor = Color.FromArgb(191, 219, 255); - } - else if (bool.Parse(item.PlcItemValue.ToString())) - { - ctn.BackColor = Color.Lime; - } - else - { - ctn.BackColor = Color.Red; - } - } + btn.BackColor = Color.Red; } - })); + } + } + + + + //private void Show_X_Y_Status(IEnumerable items) + //{ + + // BeginInvoke(new Action(() => + // { + // foreach (var item in items) + // { + // if (item.PlcItemDataType == 2) + // { + // if (this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) + // { + // CircleButton ctn = this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as CircleButton; + // if (string.IsNullOrEmpty(item.PlcItemValue)) + // { + // ctn.BackColor = Color.FromArgb(191, 219, 255); + // } + // else if (bool.Parse(item.PlcItemValue.ToString())) + // { + // ctn.BackColor = Color.Lime; + // } + // else + // { + // ctn.BackColor = Color.Red; + // } + // } + // } + // else + // { + // if (this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) + // { + // CircleButton ctn = this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as CircleButton; + // if (string.IsNullOrEmpty(item.PlcItemValue)) + // { + // ctn.BackColor = Color.FromArgb(191, 219, 255); + // } + // else if (bool.Parse(item.PlcItemValue.ToString())) + // { + // ctn.BackColor = Color.Lime; + // } + // else + // { + // ctn.BackColor = Color.Red; + // } + // } + // } + // } + // })); + //} private void initControl() { + try { if (PlcOperationHelper.Instance.PlcItemMd_X_List != null && PlcOperationHelper.Instance.PlcItemMd_X_List.Count > 0) @@ -83,15 +134,14 @@ namespace CleanMachineHMI.FrmUserControl List tempLst = PlcOperationHelper.Instance.PlcItemMd_X_List.OrderBy(x => Convert.ToInt32(x.PlcItemPriAddress)).ToList(); foreach (PlcItem item in tempLst) { - BeginInvoke(new Action(() => - { - if (this.Controls.Find("klb_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) - { - KryptonLabel label1 = this.Controls.Find("klb_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as KryptonLabel; - label1.Text = this.T(item.PlcItemName.Replace("(I/O监控)", ""), item.PlcItemCode); - } - })); + if (this.Controls.Find("klb_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) + { + KryptonLabel label1 = this.Controls.Find("klb_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as KryptonLabel; + + label1.Text = this.T(item.PlcItemName.Replace("(I/O监控)", ""), item.PlcItemCode); + } + } } @@ -100,17 +150,21 @@ namespace CleanMachineHMI.FrmUserControl List tempLst = PlcOperationHelper.Instance.PlcItemMd_Y_List.OrderBy(x => Convert.ToInt32(x.PlcItemPriAddress)).ToList(); foreach (PlcItem item in tempLst) { - BeginInvoke(new Action(() => - { - if (this.Controls.Find("klb_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) - { - KryptonLabel label1 = this.Controls.Find("klb_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as KryptonLabel; - label1.Text = this.T(item.PlcItemName.Replace("(I/O监控)", ""), item.PlcItemCode); - } - })); + if (this.Controls.Find("klb_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true).Length > 0) + { + KryptonLabel label1 = this.Controls.Find("klb_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true)[0] as KryptonLabel; + + label1.Text = this.T(item.PlcItemName.Replace("(I/O监控)", ""), item.PlcItemCode); + } + } } + + + Show_X_Y_Status(PlcOperationHelper.Instance.PlcItemMd_X_List); + + Show_X_Y_Status(PlcOperationHelper.Instance.PlcItemMd_Y_List); } catch (Exception ex) { diff --git a/CleanMachineHMI/FrmUserControl/frmMainDetail.Designer.cs b/CleanMachineHMI/FrmUserControl/frmMainDetail.Designer.cs index d3f5e17..88b5aa9 100644 --- a/CleanMachineHMI/FrmUserControl/frmMainDetail.Designer.cs +++ b/CleanMachineHMI/FrmUserControl/frmMainDetail.Designer.cs @@ -79,10 +79,13 @@ namespace CleanMachineHMI.FrmUserControl this.kdtp_RecordDate = new Krypton.Toolkit.KryptonDateTimePicker(); this.label8 = new System.Windows.Forms.Label(); this.panel1 = new System.Windows.Forms.Panel(); + this.kryptonButton8 = new Krypton.Toolkit.KryptonButton(); this.ktb_CurrPalletCode = new Krypton.Toolkit.KryptonTextBox(); this.kryptonLabel10 = new Krypton.Toolkit.KryptonLabel(); + this.ktb_ShiftCount = new Krypton.Toolkit.KryptonTextBox(); this.ktb_FinishedPalletNum = new Krypton.Toolkit.KryptonTextBox(); this.ktb_CurrentPalletNum = new Krypton.Toolkit.KryptonTextBox(); + this.kryptonLabel16 = new Krypton.Toolkit.KryptonLabel(); this.kryptonLabel15 = new Krypton.Toolkit.KryptonLabel(); this.ktb_ScrapNum = new Krypton.Toolkit.KryptonTextBox(); this.kryptonLabel14 = new Krypton.Toolkit.KryptonLabel(); @@ -97,25 +100,21 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonLabel1 = new Krypton.Toolkit.KryptonLabel(); this.kryptonLabel2 = new Krypton.Toolkit.KryptonLabel(); this.kryptonGroupBox5 = new Krypton.Toolkit.KryptonGroupBox(); - this.dwqeqw = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel24 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel13 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_Adhesives = new Krypton.Toolkit.KryptonButton(); this.knud_Adhesives = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_Adhesives_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel21 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel22 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel12 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_Solvents = new Krypton.Toolkit.KryptonButton(); this.knud_Solvents = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_Solvents_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel19 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel20 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel11 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_StrongOdor = new Krypton.Toolkit.KryptonButton(); this.knud_StrongOdor = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_StrongOdor_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel17 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel18 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel10 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_OilOrGreaseOrPaint = new Krypton.Toolkit.KryptonButton(); @@ -126,31 +125,26 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel3 = new Krypton.Toolkit.KryptonPanel(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.kryptonGroupBox2 = new Krypton.Toolkit.KryptonGroupBox(); - this.kryptonPanel4 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel33 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel21 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_TapeOrStickers = new Krypton.Toolkit.KryptonButton(); this.knud_TapeOrStickers = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_TapeOrStickers_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel15 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel16 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel9 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_RodentsInsocts = new Krypton.Toolkit.KryptonButton(); this.knud_RodentsInsocts = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_RodentsInsocts_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel13 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel14 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel8 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_DirtMudGrass = new Krypton.Toolkit.KryptonButton(); this.knud_DirtMudGrass = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_DirtMudGrass_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel11 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel12 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel7 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_MetalShaving = new Krypton.Toolkit.KryptonButton(); this.knud_MetalShaving = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_MetalShaving_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel10 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel9 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel6 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_GlassOrWoodShreds = new Krypton.Toolkit.KryptonButton(); @@ -168,25 +162,21 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel8 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel5 = new Krypton.Toolkit.KryptonWrapLabel(); this.kryptonGroupBox3 = new Krypton.Toolkit.KryptonGroupBox(); - this.kryptonPanel31 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel32 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel17 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_Mold = new Krypton.Toolkit.KryptonButton(); this.knud_Mold = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_Mold_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel29 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel30 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel16 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_OdorOrAtypicalSmell = new Krypton.Toolkit.KryptonButton(); this.knud_OdorOrAtypicalSmell = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_OdorOrAtypicalSmell_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel27 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel28 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel15 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_FecesExcreta = new Krypton.Toolkit.KryptonButton(); this.knud_FecesExcreta = new Krypton.Toolkit.KryptonNumericUpDown(); this.kbtn_FecesExcreta_1 = new Krypton.Toolkit.KryptonButton(); - this.kryptonPanel25 = new Krypton.Toolkit.KryptonPanel(); this.kryptonPanel26 = new Krypton.Toolkit.KryptonPanel(); this.kryptonWrapLabel14 = new Krypton.Toolkit.KryptonWrapLabel(); this.kbtn_MoistureOrWet = new Krypton.Toolkit.KryptonButton(); @@ -227,16 +217,12 @@ namespace CleanMachineHMI.FrmUserControl ((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox5.Panel)).BeginInit(); this.kryptonGroupBox5.Panel.SuspendLayout(); this.kryptonGroupBox5.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.dwqeqw)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel24)).BeginInit(); this.kryptonPanel24.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel21)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel22)).BeginInit(); this.kryptonPanel22.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel19)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel20)).BeginInit(); this.kryptonPanel20.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel17)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel18)).BeginInit(); this.kryptonPanel18.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).BeginInit(); @@ -248,19 +234,14 @@ namespace CleanMachineHMI.FrmUserControl ((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2.Panel)).BeginInit(); this.kryptonGroupBox2.Panel.SuspendLayout(); this.kryptonGroupBox2.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel4)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel33)).BeginInit(); this.kryptonPanel33.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel15)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel16)).BeginInit(); this.kryptonPanel16.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel13)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel14)).BeginInit(); this.kryptonPanel14.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel11)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel12)).BeginInit(); this.kryptonPanel12.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel10)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel9)).BeginInit(); this.kryptonPanel9.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel5)).BeginInit(); @@ -278,16 +259,12 @@ namespace CleanMachineHMI.FrmUserControl ((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3.Panel)).BeginInit(); this.kryptonGroupBox3.Panel.SuspendLayout(); this.kryptonGroupBox3.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel31)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel32)).BeginInit(); this.kryptonPanel32.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel29)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel30)).BeginInit(); this.kryptonPanel30.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel27)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel28)).BeginInit(); this.kryptonPanel28.SuspendLayout(); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel25)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel26)).BeginInit(); this.kryptonPanel26.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel7)).BeginInit(); @@ -301,7 +278,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox8.CaptionOverlap = 0D; this.kryptonGroupBox8.CaptionStyle = Krypton.Toolkit.LabelStyle.TitleControl; this.kryptonGroupBox8.Dock = System.Windows.Forms.DockStyle.Fill; - this.kryptonGroupBox8.Location = new System.Drawing.Point(501, 3); + this.kryptonGroupBox8.Location = new System.Drawing.Point(460, 3); this.kryptonGroupBox8.Name = "kryptonGroupBox8"; // // kryptonGroupBox8.Panel @@ -311,16 +288,16 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox8.Panel.Controls.Add(this.kbtn_forceFinish); this.kryptonGroupBox8.Panel.Controls.Add(this.label4_SD); this.kryptonGroupBox8.Panel.Controls.Add(this.kryptonButton6); - this.kryptonGroupBox8.Size = new System.Drawing.Size(199, 338); + this.kryptonGroupBox8.Size = new System.Drawing.Size(190, 401); this.kryptonGroupBox8.TabIndex = 8; this.kryptonGroupBox8.Values.Heading = ""; // // kryptonButton7 // - this.kryptonButton7.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kryptonButton7.Location = new System.Drawing.Point(28, 268); + this.kryptonButton7.Anchor = System.Windows.Forms.AnchorStyles.None; + this.kryptonButton7.Location = new System.Drawing.Point(33, 268); this.kryptonButton7.Name = "kryptonButton7"; - this.kryptonButton7.Size = new System.Drawing.Size(154, 52); + this.kryptonButton7.Size = new System.Drawing.Size(135, 52); this.kryptonButton7.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonButton7.TabIndex = 49; this.kryptonButton7.Values.Text = "Finished Print"; @@ -340,10 +317,10 @@ namespace CleanMachineHMI.FrmUserControl // // kbtn_forceFinish // - this.kbtn_forceFinish.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kbtn_forceFinish.Location = new System.Drawing.Point(28, 189); + this.kbtn_forceFinish.Anchor = System.Windows.Forms.AnchorStyles.None; + this.kbtn_forceFinish.Location = new System.Drawing.Point(33, 189); this.kbtn_forceFinish.Name = "kbtn_forceFinish"; - this.kbtn_forceFinish.Size = new System.Drawing.Size(154, 52); + this.kbtn_forceFinish.Size = new System.Drawing.Size(135, 52); this.kbtn_forceFinish.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kbtn_forceFinish.TabIndex = 2; this.kbtn_forceFinish.Values.Text = "End of IR job"; @@ -363,10 +340,10 @@ namespace CleanMachineHMI.FrmUserControl // // kryptonButton6 // - this.kryptonButton6.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kryptonButton6.Location = new System.Drawing.Point(28, 48); + this.kryptonButton6.Anchor = System.Windows.Forms.AnchorStyles.None; + this.kryptonButton6.Location = new System.Drawing.Point(33, 48); this.kryptonButton6.Name = "kryptonButton6"; - this.kryptonButton6.Size = new System.Drawing.Size(154, 52); + this.kryptonButton6.Size = new System.Drawing.Size(135, 52); this.kryptonButton6.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonButton6.TabIndex = 6; this.kryptonButton6.Values.Text = "Conveyor On"; @@ -378,7 +355,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox9.CaptionOverlap = 0D; this.kryptonGroupBox9.CaptionStyle = Krypton.Toolkit.LabelStyle.TitleControl; this.kryptonGroupBox9.Dock = System.Windows.Forms.DockStyle.Fill; - this.kryptonGroupBox9.Location = new System.Drawing.Point(279, 3); + this.kryptonGroupBox9.Location = new System.Drawing.Point(259, 3); this.kryptonGroupBox9.Name = "kryptonGroupBox9"; // // kryptonGroupBox9.Panel @@ -389,7 +366,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox9.Panel.Controls.Add(this.kryptonButton4); this.kryptonGroupBox9.Panel.Controls.Add(this.kryptonButton2); this.kryptonGroupBox9.Panel.Controls.Add(this.kryptonButton3); - this.kryptonGroupBox9.Size = new System.Drawing.Size(216, 338); + this.kryptonGroupBox9.Size = new System.Drawing.Size(195, 401); this.kryptonGroupBox9.TabIndex = 7; this.kryptonGroupBox9.Values.Heading = ""; // @@ -420,7 +397,7 @@ namespace CleanMachineHMI.FrmUserControl // kryptonButton5 // this.kryptonButton5.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kryptonButton5.Location = new System.Drawing.Point(36, 273); + this.kryptonButton5.Location = new System.Drawing.Point(1, 273); this.kryptonButton5.Name = "kryptonButton5"; this.kryptonButton5.RightToLeft = System.Windows.Forms.RightToLeft.Yes; this.kryptonButton5.Size = new System.Drawing.Size(154, 47); @@ -434,7 +411,7 @@ namespace CleanMachineHMI.FrmUserControl // kryptonButton4 // this.kryptonButton4.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kryptonButton4.Location = new System.Drawing.Point(36, 202); + this.kryptonButton4.Location = new System.Drawing.Point(1, 202); this.kryptonButton4.Name = "kryptonButton4"; this.kryptonButton4.RightToLeft = System.Windows.Forms.RightToLeft.Yes; this.kryptonButton4.Size = new System.Drawing.Size(154, 47); @@ -448,7 +425,7 @@ namespace CleanMachineHMI.FrmUserControl // kryptonButton2 // this.kryptonButton2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kryptonButton2.Location = new System.Drawing.Point(36, 99); + this.kryptonButton2.Location = new System.Drawing.Point(15, 99); this.kryptonButton2.Name = "kryptonButton2"; this.kryptonButton2.Size = new System.Drawing.Size(154, 35); this.kryptonButton2.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -460,7 +437,7 @@ namespace CleanMachineHMI.FrmUserControl // kryptonButton3 // this.kryptonButton3.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kryptonButton3.Location = new System.Drawing.Point(36, 47); + this.kryptonButton3.Location = new System.Drawing.Point(15, 47); this.kryptonButton3.Name = "kryptonButton3"; this.kryptonButton3.Size = new System.Drawing.Size(154, 35); this.kryptonButton3.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -471,9 +448,9 @@ namespace CleanMachineHMI.FrmUserControl // // knud_WorkedFullPalletNum // - this.knud_WorkedFullPalletNum.Location = new System.Drawing.Point(16, 230); + this.knud_WorkedFullPalletNum.Location = new System.Drawing.Point(100, 276); this.knud_WorkedFullPalletNum.Name = "knud_WorkedFullPalletNum"; - this.knud_WorkedFullPalletNum.Size = new System.Drawing.Size(84, 30); + this.knud_WorkedFullPalletNum.Size = new System.Drawing.Size(54, 30); this.knud_WorkedFullPalletNum.StateCommon.Content.Font = new System.Drawing.Font("宋体", 15F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_WorkedFullPalletNum.TabIndex = 48; this.knud_WorkedFullPalletNum.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; @@ -513,7 +490,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox7.Panel.Controls.Add(this.kryptonLabel9); this.kryptonGroupBox7.Panel.Controls.Add(this.swtbtn_brush2); this.kryptonGroupBox7.Panel.Controls.Add(this.cbt_Brush2StatusTran); - this.kryptonGroupBox7.Size = new System.Drawing.Size(270, 338); + this.kryptonGroupBox7.Size = new System.Drawing.Size(250, 401); this.kryptonGroupBox7.TabIndex = 5; this.kryptonGroupBox7.Values.Heading = ""; // @@ -812,10 +789,10 @@ namespace CleanMachineHMI.FrmUserControl // this.tableLayoutPanel2.BackColor = System.Drawing.Color.Transparent; this.tableLayoutPanel2.ColumnCount = 4; - this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 26F)); - this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20.93254F)); - this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 19.34524F)); - this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.53175F)); + this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 24.10546F)); + this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 18.92655F)); + this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 18.45574F)); + this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 38.51224F)); this.tableLayoutPanel2.Controls.Add(this.kryptonGroupBox8, 0, 0); this.tableLayoutPanel2.Controls.Add(this.kryptonGroupBox9, 0, 0); this.tableLayoutPanel2.Controls.Add(this.kryptonGroupBox7, 0, 0); @@ -825,14 +802,14 @@ namespace CleanMachineHMI.FrmUserControl this.tableLayoutPanel2.Name = "tableLayoutPanel2"; this.tableLayoutPanel2.RowCount = 1; this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel2.Size = new System.Drawing.Size(1062, 344); + this.tableLayoutPanel2.Size = new System.Drawing.Size(1062, 407); this.tableLayoutPanel2.TabIndex = 10; // // kryptonGroupBox1 // this.kryptonGroupBox1.CaptionOverlap = 0D; this.kryptonGroupBox1.Dock = System.Windows.Forms.DockStyle.Fill; - this.kryptonGroupBox1.Location = new System.Drawing.Point(706, 3); + this.kryptonGroupBox1.Location = new System.Drawing.Point(656, 3); this.kryptonGroupBox1.Name = "kryptonGroupBox1"; // // kryptonGroupBox1.Panel @@ -848,19 +825,18 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox1.Panel.Controls.Add(this.label8); this.kryptonGroupBox1.Panel.Controls.Add(this.panel1); this.kryptonGroupBox1.Panel.Controls.Add(this.label7); - this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonButton1); this.kryptonGroupBox1.Panel.Controls.Add(this.ktb_SaveIR); this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonLabel3); this.kryptonGroupBox1.Panel.Controls.Add(this.ktb_IR); this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonLabel1); this.kryptonGroupBox1.Panel.Controls.Add(this.kryptonLabel2); - this.kryptonGroupBox1.Size = new System.Drawing.Size(353, 338); + this.kryptonGroupBox1.Size = new System.Drawing.Size(403, 401); this.kryptonGroupBox1.TabIndex = 9; this.kryptonGroupBox1.Values.Heading = ""; // // kryptonLabel13 // - this.kryptonLabel13.Location = new System.Drawing.Point(99, 234); + this.kryptonLabel13.Location = new System.Drawing.Point(151, 279); this.kryptonLabel13.Name = "kryptonLabel13"; this.kryptonLabel13.Size = new System.Drawing.Size(55, 20); this.kryptonLabel13.StateCommon.ShortText.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -869,7 +845,7 @@ namespace CleanMachineHMI.FrmUserControl // // kbtn_WorkedFullPalletNum // - this.kbtn_WorkedFullPalletNum.Location = new System.Drawing.Point(158, 230); + this.kbtn_WorkedFullPalletNum.Location = new System.Drawing.Point(204, 275); this.kbtn_WorkedFullPalletNum.Name = "kbtn_WorkedFullPalletNum"; this.kbtn_WorkedFullPalletNum.Size = new System.Drawing.Size(170, 30); this.kbtn_WorkedFullPalletNum.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -884,16 +860,16 @@ namespace CleanMachineHMI.FrmUserControl this.kcmb_SheetType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; this.kcmb_SheetType.DropDownWidth = 211; this.kcmb_SheetType.IntegralHeight = false; - this.kcmb_SheetType.Location = new System.Drawing.Point(131, 3); + this.kcmb_SheetType.Location = new System.Drawing.Point(104, 3); this.kcmb_SheetType.Name = "kcmb_SheetType"; - this.kcmb_SheetType.Size = new System.Drawing.Size(211, 21); + this.kcmb_SheetType.Size = new System.Drawing.Size(184, 21); this.kcmb_SheetType.StateCommon.ComboBox.Content.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kcmb_SheetType.TabIndex = 10; // // kbtn_Scrap_1 // this.kbtn_Scrap_1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kbtn_Scrap_1.Location = new System.Drawing.Point(261, 263); + this.kbtn_Scrap_1.Location = new System.Drawing.Point(334, 323); this.kbtn_Scrap_1.Name = "kbtn_Scrap_1"; this.kbtn_Scrap_1.Size = new System.Drawing.Size(60, 60); this.kbtn_Scrap_1.StateCommon.Back.Color1 = System.Drawing.Color.FromArgb(((int)(((byte)(237)))), ((int)(((byte)(64)))), ((int)(((byte)(20))))); @@ -908,7 +884,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_Scrap // this.kbtn_Scrap.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kbtn_Scrap.Location = new System.Drawing.Point(45, 263); + this.kbtn_Scrap.Location = new System.Drawing.Point(94, 323); this.kbtn_Scrap.Name = "kbtn_Scrap"; this.kbtn_Scrap.Size = new System.Drawing.Size(60, 60); this.kbtn_Scrap.StateCommon.Back.Color1 = System.Drawing.Color.FromArgb(((int)(((byte)(237)))), ((int)(((byte)(64)))), ((int)(((byte)(20))))); @@ -923,7 +899,7 @@ namespace CleanMachineHMI.FrmUserControl // ktb_Scrap // this.ktb_Scrap.AlwaysActive = false; - this.ktb_Scrap.Location = new System.Drawing.Point(108, 299); + this.ktb_Scrap.Location = new System.Drawing.Point(184, 355); this.ktb_Scrap.Name = "ktb_Scrap"; this.ktb_Scrap.ReadOnly = true; this.ktb_Scrap.Size = new System.Drawing.Size(121, 23); @@ -935,10 +911,10 @@ namespace CleanMachineHMI.FrmUserControl this.kdtp_RecordDate.CalendarTodayDate = new System.DateTime(2020, 10, 23, 0, 0, 0, 0); this.kdtp_RecordDate.CustomFormat = "yyyy-MM-dd HH:mm:ss"; this.kdtp_RecordDate.Format = System.Windows.Forms.DateTimePickerFormat.Custom; - this.kdtp_RecordDate.Location = new System.Drawing.Point(131, 47); + this.kdtp_RecordDate.Location = new System.Drawing.Point(104, 52); this.kdtp_RecordDate.Name = "kdtp_RecordDate"; this.kdtp_RecordDate.ShowCheckBox = true; - this.kdtp_RecordDate.Size = new System.Drawing.Size(211, 21); + this.kdtp_RecordDate.Size = new System.Drawing.Size(184, 21); this.kdtp_RecordDate.TabIndex = 4; // // label8 @@ -947,7 +923,7 @@ namespace CleanMachineHMI.FrmUserControl this.label8.BackColor = System.Drawing.Color.Transparent; this.label8.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label8.ForeColor = System.Drawing.Color.Black; - this.label8.Location = new System.Drawing.Point(126, 267); + this.label8.Location = new System.Drawing.Point(202, 323); this.label8.Name = "label8"; this.label8.Size = new System.Drawing.Size(75, 12); this.label8.TabIndex = 8; @@ -957,61 +933,96 @@ namespace CleanMachineHMI.FrmUserControl // this.panel1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; + this.panel1.Controls.Add(this.kryptonButton8); this.panel1.Controls.Add(this.ktb_CurrPalletCode); this.panel1.Controls.Add(this.kryptonLabel10); + this.panel1.Controls.Add(this.ktb_ShiftCount); this.panel1.Controls.Add(this.ktb_FinishedPalletNum); this.panel1.Controls.Add(this.ktb_CurrentPalletNum); + this.panel1.Controls.Add(this.kryptonLabel16); this.panel1.Controls.Add(this.kryptonLabel15); this.panel1.Controls.Add(this.ktb_ScrapNum); this.panel1.Controls.Add(this.kryptonLabel14); this.panel1.Controls.Add(this.ktb_CompleteNum); this.panel1.Controls.Add(this.kryptonLabel5); this.panel1.Controls.Add(this.kryptonLabel4); - this.panel1.Location = new System.Drawing.Point(29, 97); + this.panel1.Location = new System.Drawing.Point(76, 79); this.panel1.Name = "panel1"; - this.panel1.Size = new System.Drawing.Size(312, 130); + this.panel1.Size = new System.Drawing.Size(318, 190); this.panel1.TabIndex = 3; // + // kryptonButton8 + // + this.kryptonButton8.Location = new System.Drawing.Point(224, 158); + this.kryptonButton8.Name = "kryptonButton8"; + this.kryptonButton8.Size = new System.Drawing.Size(73, 26); + this.kryptonButton8.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + this.kryptonButton8.TabIndex = 49; + this.kryptonButton8.Values.Text = "reset"; + this.kryptonButton8.Click += new System.EventHandler(this.kryptonButton8_Click); + // // ktb_CurrPalletCode // this.ktb_CurrPalletCode.AlwaysActive = false; - this.ktb_CurrPalletCode.Location = new System.Drawing.Point(141, 52); + this.ktb_CurrPalletCode.Location = new System.Drawing.Point(147, 68); this.ktb_CurrPalletCode.Name = "ktb_CurrPalletCode"; this.ktb_CurrPalletCode.ReadOnly = true; this.ktb_CurrPalletCode.Size = new System.Drawing.Size(150, 23); this.ktb_CurrPalletCode.TabIndex = 10; + this.ktb_CurrPalletCode.TextAlign = System.Windows.Forms.HorizontalAlignment.Right; // // kryptonLabel10 // this.kryptonLabel10.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel10.Location = new System.Drawing.Point(16, 53); + this.kryptonLabel10.Location = new System.Drawing.Point(23, 69); this.kryptonLabel10.Name = "kryptonLabel10"; this.kryptonLabel10.Size = new System.Drawing.Size(124, 20); this.kryptonLabel10.TabIndex = 9; this.kryptonLabel10.Values.Text = "Current Pallet Code"; // + // ktb_ShiftCount + // + this.ktb_ShiftCount.AlwaysActive = false; + this.ktb_ShiftCount.Location = new System.Drawing.Point(147, 161); + this.ktb_ShiftCount.Name = "ktb_ShiftCount"; + this.ktb_ShiftCount.ReadOnly = true; + this.ktb_ShiftCount.Size = new System.Drawing.Size(71, 23); + this.ktb_ShiftCount.TabIndex = 1; + this.ktb_ShiftCount.TextAlign = System.Windows.Forms.HorizontalAlignment.Right; + // // ktb_FinishedPalletNum // this.ktb_FinishedPalletNum.AlwaysActive = false; - this.ktb_FinishedPalletNum.Location = new System.Drawing.Point(141, 102); + this.ktb_FinishedPalletNum.Location = new System.Drawing.Point(147, 130); this.ktb_FinishedPalletNum.Name = "ktb_FinishedPalletNum"; this.ktb_FinishedPalletNum.ReadOnly = true; this.ktb_FinishedPalletNum.Size = new System.Drawing.Size(150, 23); this.ktb_FinishedPalletNum.TabIndex = 1; + this.ktb_FinishedPalletNum.TextAlign = System.Windows.Forms.HorizontalAlignment.Right; // // ktb_CurrentPalletNum // this.ktb_CurrentPalletNum.AlwaysActive = false; - this.ktb_CurrentPalletNum.Location = new System.Drawing.Point(141, 77); + this.ktb_CurrentPalletNum.Location = new System.Drawing.Point(147, 99); this.ktb_CurrentPalletNum.Name = "ktb_CurrentPalletNum"; this.ktb_CurrentPalletNum.ReadOnly = true; this.ktb_CurrentPalletNum.Size = new System.Drawing.Size(150, 23); this.ktb_CurrentPalletNum.TabIndex = 1; + this.ktb_CurrentPalletNum.TextAlign = System.Windows.Forms.HorizontalAlignment.Right; + // + // kryptonLabel16 + // + this.kryptonLabel16.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; + this.kryptonLabel16.Location = new System.Drawing.Point(71, 162); + this.kryptonLabel16.Name = "kryptonLabel16"; + this.kryptonLabel16.Size = new System.Drawing.Size(76, 20); + this.kryptonLabel16.TabIndex = 0; + this.kryptonLabel16.Values.Text = "Shift Count"; // // kryptonLabel15 // this.kryptonLabel15.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel15.Location = new System.Drawing.Point(12, 103); + this.kryptonLabel15.Location = new System.Drawing.Point(20, 131); this.kryptonLabel15.Name = "kryptonLabel15"; this.kryptonLabel15.Size = new System.Drawing.Size(127, 20); this.kryptonLabel15.TabIndex = 0; @@ -1020,16 +1031,17 @@ namespace CleanMachineHMI.FrmUserControl // ktb_ScrapNum // this.ktb_ScrapNum.AlwaysActive = false; - this.ktb_ScrapNum.Location = new System.Drawing.Point(141, 27); + this.ktb_ScrapNum.Location = new System.Drawing.Point(147, 37); this.ktb_ScrapNum.Name = "ktb_ScrapNum"; this.ktb_ScrapNum.ReadOnly = true; this.ktb_ScrapNum.Size = new System.Drawing.Size(150, 23); this.ktb_ScrapNum.TabIndex = 1; + this.ktb_ScrapNum.TextAlign = System.Windows.Forms.HorizontalAlignment.Right; // // kryptonLabel14 // this.kryptonLabel14.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel14.Location = new System.Drawing.Point(16, 79); + this.kryptonLabel14.Location = new System.Drawing.Point(24, 100); this.kryptonLabel14.Name = "kryptonLabel14"; this.kryptonLabel14.Size = new System.Drawing.Size(123, 20); this.kryptonLabel14.TabIndex = 0; @@ -1038,16 +1050,17 @@ namespace CleanMachineHMI.FrmUserControl // ktb_CompleteNum // this.ktb_CompleteNum.AlwaysActive = false; - this.ktb_CompleteNum.Location = new System.Drawing.Point(141, 2); + this.ktb_CompleteNum.Location = new System.Drawing.Point(147, 6); this.ktb_CompleteNum.Name = "ktb_CompleteNum"; this.ktb_CompleteNum.ReadOnly = true; this.ktb_CompleteNum.Size = new System.Drawing.Size(150, 23); this.ktb_CompleteNum.TabIndex = 1; + this.ktb_CompleteNum.TextAlign = System.Windows.Forms.HorizontalAlignment.Right; // // kryptonLabel5 // this.kryptonLabel5.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel5.Location = new System.Drawing.Point(40, 30); + this.kryptonLabel5.Location = new System.Drawing.Point(50, 38); this.kryptonLabel5.Name = "kryptonLabel5"; this.kryptonLabel5.Size = new System.Drawing.Size(97, 20); this.kryptonLabel5.TabIndex = 0; @@ -1056,7 +1069,7 @@ namespace CleanMachineHMI.FrmUserControl // kryptonLabel4 // this.kryptonLabel4.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel4.Location = new System.Drawing.Point(42, 5); + this.kryptonLabel4.Location = new System.Drawing.Point(52, 7); this.kryptonLabel4.Name = "kryptonLabel4"; this.kryptonLabel4.Size = new System.Drawing.Size(95, 20); this.kryptonLabel4.TabIndex = 0; @@ -1068,7 +1081,7 @@ namespace CleanMachineHMI.FrmUserControl this.label7.BackColor = System.Drawing.Color.Transparent; this.label7.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.label7.ForeColor = System.Drawing.Color.Black; - this.label7.Location = new System.Drawing.Point(126, 285); + this.label7.Location = new System.Drawing.Point(202, 341); this.label7.Name = "label7"; this.label7.Size = new System.Drawing.Size(82, 12); this.label7.TabIndex = 8; @@ -1077,9 +1090,9 @@ namespace CleanMachineHMI.FrmUserControl // kryptonButton1 // this.kryptonButton1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.kryptonButton1.Location = new System.Drawing.Point(131, 69); + this.kryptonButton1.Location = new System.Drawing.Point(156, 160); this.kryptonButton1.Name = "kryptonButton1"; - this.kryptonButton1.Size = new System.Drawing.Size(97, 25); + this.kryptonButton1.Size = new System.Drawing.Size(84, 25); this.kryptonButton1.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonButton1.TabIndex = 2; this.kryptonButton1.Values.Text = "ReEntry"; @@ -1089,9 +1102,10 @@ namespace CleanMachineHMI.FrmUserControl // ktb_SaveIR // this.ktb_SaveIR.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.ktb_SaveIR.Location = new System.Drawing.Point(244, 69); + this.ktb_SaveIR.AutoSize = true; + this.ktb_SaveIR.Location = new System.Drawing.Point(294, 3); this.ktb_SaveIR.Name = "ktb_SaveIR"; - this.ktb_SaveIR.Size = new System.Drawing.Size(97, 25); + this.ktb_SaveIR.Size = new System.Drawing.Size(100, 70); this.ktb_SaveIR.StateCommon.Content.ShortText.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.ktb_SaveIR.TabIndex = 2; this.ktb_SaveIR.Values.Text = "SAVE IR"; @@ -1101,7 +1115,7 @@ namespace CleanMachineHMI.FrmUserControl // this.kryptonLabel3.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.kryptonLabel3.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel3.Location = new System.Drawing.Point(45, 46); + this.kryptonLabel3.Location = new System.Drawing.Point(16, 53); this.kryptonLabel3.Name = "kryptonLabel3"; this.kryptonLabel3.Size = new System.Drawing.Size(82, 20); this.kryptonLabel3.TabIndex = 0; @@ -1110,9 +1124,9 @@ namespace CleanMachineHMI.FrmUserControl // ktb_IR // this.ktb_IR.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); - this.ktb_IR.Location = new System.Drawing.Point(131, 24); + this.ktb_IR.Location = new System.Drawing.Point(104, 27); this.ktb_IR.Name = "ktb_IR"; - this.ktb_IR.Size = new System.Drawing.Size(211, 23); + this.ktb_IR.Size = new System.Drawing.Size(184, 23); this.ktb_IR.TabIndex = 1; this.ktb_IR.TextChanged += new System.EventHandler(this.ktb_IR_TextChanged_1); // @@ -1120,7 +1134,7 @@ namespace CleanMachineHMI.FrmUserControl // this.kryptonLabel1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.kryptonLabel1.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel1.Location = new System.Drawing.Point(92, 24); + this.kryptonLabel1.Location = new System.Drawing.Point(65, 25); this.kryptonLabel1.Name = "kryptonLabel1"; this.kryptonLabel1.Size = new System.Drawing.Size(33, 20); this.kryptonLabel1.TabIndex = 0; @@ -1130,7 +1144,7 @@ namespace CleanMachineHMI.FrmUserControl // this.kryptonLabel2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.kryptonLabel2.LabelStyle = Krypton.Toolkit.LabelStyle.BoldControl; - this.kryptonLabel2.Location = new System.Drawing.Point(52, 3); + this.kryptonLabel2.Location = new System.Drawing.Point(23, 4); this.kryptonLabel2.Name = "kryptonLabel2"; this.kryptonLabel2.Size = new System.Drawing.Size(75, 20); this.kryptonLabel2.TabIndex = 0; @@ -1146,27 +1160,15 @@ namespace CleanMachineHMI.FrmUserControl // // kryptonGroupBox5.Panel // - this.kryptonGroupBox5.Panel.Controls.Add(this.dwqeqw); this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel24); - this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel21); this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel22); - this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel19); this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel20); - this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel17); this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel18); this.kryptonGroupBox5.Panel.Controls.Add(this.kryptonPanel6); - this.kryptonGroupBox5.Size = new System.Drawing.Size(259, 270); + this.kryptonGroupBox5.Size = new System.Drawing.Size(259, 207); this.kryptonGroupBox5.TabIndex = 3; this.kryptonGroupBox5.Values.Heading = ""; // - // dwqeqw - // - this.dwqeqw.Dock = System.Windows.Forms.DockStyle.Top; - this.dwqeqw.Location = new System.Drawing.Point(0, 146); - this.dwqeqw.Name = "dwqeqw"; - this.dwqeqw.Size = new System.Drawing.Size(255, 7); - this.dwqeqw.TabIndex = 10; - // // kryptonPanel24 // this.kryptonPanel24.Controls.Add(this.kryptonWrapLabel13); @@ -1174,7 +1176,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel24.Controls.Add(this.knud_Adhesives); this.kryptonPanel24.Controls.Add(this.kbtn_Adhesives_1); this.kryptonPanel24.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel24.Location = new System.Drawing.Point(0, 121); + this.kryptonPanel24.Location = new System.Drawing.Point(0, 100); this.kryptonPanel24.Name = "kryptonPanel24"; this.kryptonPanel24.Size = new System.Drawing.Size(255, 25); this.kryptonPanel24.TabIndex = 9; @@ -1188,7 +1190,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel13.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel13.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel13.Name = "kryptonWrapLabel13"; - this.kryptonWrapLabel13.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel13.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel13.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel13.Text = "粘合剂"; this.kryptonWrapLabel13.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1196,7 +1198,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_Adhesives // this.kbtn_Adhesives.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_Adhesives.Location = new System.Drawing.Point(145, 0); + this.kbtn_Adhesives.Location = new System.Drawing.Point(143, 0); this.kbtn_Adhesives.Name = "kbtn_Adhesives"; this.kbtn_Adhesives.Size = new System.Drawing.Size(28, 25); this.kbtn_Adhesives.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1208,7 +1210,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_Adhesives.Dock = System.Windows.Forms.DockStyle.Right; this.knud_Adhesives.Enabled = false; - this.knud_Adhesives.Location = new System.Drawing.Point(173, 0); + this.knud_Adhesives.Location = new System.Drawing.Point(171, 0); this.knud_Adhesives.Maximum = new decimal(new int[] { 200, 0, @@ -1216,7 +1218,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_Adhesives.Name = "knud_Adhesives"; this.knud_Adhesives.ReadOnly = true; - this.knud_Adhesives.Size = new System.Drawing.Size(54, 25); + this.knud_Adhesives.Size = new System.Drawing.Size(56, 25); this.knud_Adhesives.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_Adhesives.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_Adhesives.TabIndex = 3; @@ -1232,14 +1234,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_Adhesives_1.Values.Text = "-1"; this.kbtn_Adhesives_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel21 - // - this.kryptonPanel21.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel21.Location = new System.Drawing.Point(0, 114); - this.kryptonPanel21.Name = "kryptonPanel21"; - this.kryptonPanel21.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel21.TabIndex = 8; - // // kryptonPanel22 // this.kryptonPanel22.Controls.Add(this.kryptonWrapLabel12); @@ -1247,7 +1241,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel22.Controls.Add(this.knud_Solvents); this.kryptonPanel22.Controls.Add(this.kbtn_Solvents_1); this.kryptonPanel22.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel22.Location = new System.Drawing.Point(0, 89); + this.kryptonPanel22.Location = new System.Drawing.Point(0, 75); this.kryptonPanel22.Name = "kryptonPanel22"; this.kryptonPanel22.Size = new System.Drawing.Size(255, 25); this.kryptonPanel22.TabIndex = 7; @@ -1261,7 +1255,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel12.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel12.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel12.Name = "kryptonWrapLabel12"; - this.kryptonWrapLabel12.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel12.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel12.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel12.Text = "溶剂"; this.kryptonWrapLabel12.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1269,7 +1263,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_Solvents // this.kbtn_Solvents.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_Solvents.Location = new System.Drawing.Point(145, 0); + this.kbtn_Solvents.Location = new System.Drawing.Point(143, 0); this.kbtn_Solvents.Name = "kbtn_Solvents"; this.kbtn_Solvents.Size = new System.Drawing.Size(28, 25); this.kbtn_Solvents.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1281,7 +1275,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_Solvents.Dock = System.Windows.Forms.DockStyle.Right; this.knud_Solvents.Enabled = false; - this.knud_Solvents.Location = new System.Drawing.Point(173, 0); + this.knud_Solvents.Location = new System.Drawing.Point(171, 0); this.knud_Solvents.Maximum = new decimal(new int[] { 200, 0, @@ -1289,7 +1283,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_Solvents.Name = "knud_Solvents"; this.knud_Solvents.ReadOnly = true; - this.knud_Solvents.Size = new System.Drawing.Size(54, 25); + this.knud_Solvents.Size = new System.Drawing.Size(56, 25); this.knud_Solvents.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_Solvents.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_Solvents.TabIndex = 3; @@ -1305,14 +1299,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_Solvents_1.Values.Text = "-1"; this.kbtn_Solvents_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel19 - // - this.kryptonPanel19.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel19.Location = new System.Drawing.Point(0, 82); - this.kryptonPanel19.Name = "kryptonPanel19"; - this.kryptonPanel19.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel19.TabIndex = 6; - // // kryptonPanel20 // this.kryptonPanel20.Controls.Add(this.kryptonWrapLabel11); @@ -1320,7 +1306,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel20.Controls.Add(this.knud_StrongOdor); this.kryptonPanel20.Controls.Add(this.kbtn_StrongOdor_1); this.kryptonPanel20.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel20.Location = new System.Drawing.Point(0, 57); + this.kryptonPanel20.Location = new System.Drawing.Point(0, 50); this.kryptonPanel20.Name = "kryptonPanel20"; this.kryptonPanel20.Size = new System.Drawing.Size(255, 25); this.kryptonPanel20.TabIndex = 5; @@ -1334,7 +1320,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel11.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel11.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel11.Name = "kryptonWrapLabel11"; - this.kryptonWrapLabel11.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel11.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel11.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel11.Text = "强烈气味"; this.kryptonWrapLabel11.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1342,7 +1328,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_StrongOdor // this.kbtn_StrongOdor.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_StrongOdor.Location = new System.Drawing.Point(145, 0); + this.kbtn_StrongOdor.Location = new System.Drawing.Point(143, 0); this.kbtn_StrongOdor.Name = "kbtn_StrongOdor"; this.kbtn_StrongOdor.Size = new System.Drawing.Size(28, 25); this.kbtn_StrongOdor.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1354,7 +1340,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_StrongOdor.Dock = System.Windows.Forms.DockStyle.Right; this.knud_StrongOdor.Enabled = false; - this.knud_StrongOdor.Location = new System.Drawing.Point(173, 0); + this.knud_StrongOdor.Location = new System.Drawing.Point(171, 0); this.knud_StrongOdor.Maximum = new decimal(new int[] { 200, 0, @@ -1362,7 +1348,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_StrongOdor.Name = "knud_StrongOdor"; this.knud_StrongOdor.ReadOnly = true; - this.knud_StrongOdor.Size = new System.Drawing.Size(54, 25); + this.knud_StrongOdor.Size = new System.Drawing.Size(56, 25); this.knud_StrongOdor.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_StrongOdor.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_StrongOdor.TabIndex = 3; @@ -1378,14 +1364,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_StrongOdor_1.Values.Text = "-1"; this.kbtn_StrongOdor_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel17 - // - this.kryptonPanel17.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel17.Location = new System.Drawing.Point(0, 50); - this.kryptonPanel17.Name = "kryptonPanel17"; - this.kryptonPanel17.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel17.TabIndex = 4; - // // kryptonPanel18 // this.kryptonPanel18.Controls.Add(this.kryptonWrapLabel10); @@ -1407,7 +1385,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel10.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel10.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel10.Name = "kryptonWrapLabel10"; - this.kryptonWrapLabel10.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel10.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel10.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel10.Text = "油/油脂或油漆"; this.kryptonWrapLabel10.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1415,7 +1393,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_OilOrGreaseOrPaint // this.kbtn_OilOrGreaseOrPaint.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_OilOrGreaseOrPaint.Location = new System.Drawing.Point(145, 0); + this.kbtn_OilOrGreaseOrPaint.Location = new System.Drawing.Point(143, 0); this.kbtn_OilOrGreaseOrPaint.Name = "kbtn_OilOrGreaseOrPaint"; this.kbtn_OilOrGreaseOrPaint.Size = new System.Drawing.Size(28, 25); this.kbtn_OilOrGreaseOrPaint.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1427,7 +1405,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_OilOrGreaseOrPaint.Dock = System.Windows.Forms.DockStyle.Right; this.knud_OilOrGreaseOrPaint.Enabled = false; - this.knud_OilOrGreaseOrPaint.Location = new System.Drawing.Point(173, 0); + this.knud_OilOrGreaseOrPaint.Location = new System.Drawing.Point(171, 0); this.knud_OilOrGreaseOrPaint.Maximum = new decimal(new int[] { 200, 0, @@ -1435,7 +1413,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_OilOrGreaseOrPaint.Name = "knud_OilOrGreaseOrPaint"; this.knud_OilOrGreaseOrPaint.ReadOnly = true; - this.knud_OilOrGreaseOrPaint.Size = new System.Drawing.Size(54, 25); + this.knud_OilOrGreaseOrPaint.Size = new System.Drawing.Size(56, 25); this.knud_OilOrGreaseOrPaint.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_OilOrGreaseOrPaint.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_OilOrGreaseOrPaint.TabIndex = 3; @@ -1498,32 +1476,32 @@ namespace CleanMachineHMI.FrmUserControl this.tableLayoutPanel1.Controls.Add(this.kryptonGroupBox3, 2, 0); this.tableLayoutPanel1.Controls.Add(this.kryptonGroupBox5, 1, 0); this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; - this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 344); + this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 407); this.tableLayoutPanel1.Name = "tableLayoutPanel1"; this.tableLayoutPanel1.RowCount = 1; this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 276F)); - this.tableLayoutPanel1.Size = new System.Drawing.Size(1062, 276); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 195F)); + this.tableLayoutPanel1.Size = new System.Drawing.Size(1062, 213); this.tableLayoutPanel1.TabIndex = 8; // // kryptonGroupBox2 @@ -1536,29 +1514,16 @@ namespace CleanMachineHMI.FrmUserControl // // kryptonGroupBox2.Panel // - this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel4); this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel33); - this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel15); this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel16); - this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel13); this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel14); - this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel11); this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel12); - this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel10); this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel9); this.kryptonGroupBox2.Panel.Controls.Add(this.kryptonPanel5); - this.kryptonGroupBox2.Size = new System.Drawing.Size(259, 270); + this.kryptonGroupBox2.Size = new System.Drawing.Size(259, 207); this.kryptonGroupBox2.TabIndex = 4; this.kryptonGroupBox2.Values.Heading = ""; // - // kryptonPanel4 - // - this.kryptonPanel4.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel4.Location = new System.Drawing.Point(0, 178); - this.kryptonPanel4.Name = "kryptonPanel4"; - this.kryptonPanel4.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel4.TabIndex = 10; - // // kryptonPanel33 // this.kryptonPanel33.Controls.Add(this.kryptonWrapLabel21); @@ -1566,7 +1531,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel33.Controls.Add(this.knud_TapeOrStickers); this.kryptonPanel33.Controls.Add(this.kbtn_TapeOrStickers_1); this.kryptonPanel33.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel33.Location = new System.Drawing.Point(0, 153); + this.kryptonPanel33.Location = new System.Drawing.Point(0, 125); this.kryptonPanel33.Name = "kryptonPanel33"; this.kryptonPanel33.Size = new System.Drawing.Size(255, 25); this.kryptonPanel33.TabIndex = 9; @@ -1580,7 +1545,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel21.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel21.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel21.Name = "kryptonWrapLabel21"; - this.kryptonWrapLabel21.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel21.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel21.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel21.Text = "胶带、贴纸"; this.kryptonWrapLabel21.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1588,7 +1553,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_TapeOrStickers // this.kbtn_TapeOrStickers.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_TapeOrStickers.Location = new System.Drawing.Point(145, 0); + this.kbtn_TapeOrStickers.Location = new System.Drawing.Point(143, 0); this.kbtn_TapeOrStickers.Name = "kbtn_TapeOrStickers"; this.kbtn_TapeOrStickers.Size = new System.Drawing.Size(28, 25); this.kbtn_TapeOrStickers.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1600,7 +1565,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_TapeOrStickers.Dock = System.Windows.Forms.DockStyle.Right; this.knud_TapeOrStickers.Enabled = false; - this.knud_TapeOrStickers.Location = new System.Drawing.Point(173, 0); + this.knud_TapeOrStickers.Location = new System.Drawing.Point(171, 0); this.knud_TapeOrStickers.Maximum = new decimal(new int[] { 200, 0, @@ -1608,7 +1573,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_TapeOrStickers.Name = "knud_TapeOrStickers"; this.knud_TapeOrStickers.ReadOnly = true; - this.knud_TapeOrStickers.Size = new System.Drawing.Size(54, 25); + this.knud_TapeOrStickers.Size = new System.Drawing.Size(56, 25); this.knud_TapeOrStickers.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_TapeOrStickers.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_TapeOrStickers.TabIndex = 3; @@ -1624,14 +1589,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_TapeOrStickers_1.Values.Text = "-1"; this.kbtn_TapeOrStickers_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel15 - // - this.kryptonPanel15.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel15.Location = new System.Drawing.Point(0, 146); - this.kryptonPanel15.Name = "kryptonPanel15"; - this.kryptonPanel15.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel15.TabIndex = 8; - // // kryptonPanel16 // this.kryptonPanel16.Controls.Add(this.kryptonWrapLabel9); @@ -1639,7 +1596,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel16.Controls.Add(this.knud_RodentsInsocts); this.kryptonPanel16.Controls.Add(this.kbtn_RodentsInsocts_1); this.kryptonPanel16.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel16.Location = new System.Drawing.Point(0, 121); + this.kryptonPanel16.Location = new System.Drawing.Point(0, 100); this.kryptonPanel16.Name = "kryptonPanel16"; this.kryptonPanel16.Size = new System.Drawing.Size(255, 25); this.kryptonPanel16.TabIndex = 7; @@ -1653,7 +1610,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel9.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel9.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel9.Name = "kryptonWrapLabel9"; - this.kryptonWrapLabel9.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel9.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel9.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel9.Text = "啮齿动物、昆虫"; this.kryptonWrapLabel9.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1661,7 +1618,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_RodentsInsocts // this.kbtn_RodentsInsocts.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_RodentsInsocts.Location = new System.Drawing.Point(145, 0); + this.kbtn_RodentsInsocts.Location = new System.Drawing.Point(143, 0); this.kbtn_RodentsInsocts.Name = "kbtn_RodentsInsocts"; this.kbtn_RodentsInsocts.Size = new System.Drawing.Size(28, 25); this.kbtn_RodentsInsocts.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1673,7 +1630,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_RodentsInsocts.Dock = System.Windows.Forms.DockStyle.Right; this.knud_RodentsInsocts.Enabled = false; - this.knud_RodentsInsocts.Location = new System.Drawing.Point(173, 0); + this.knud_RodentsInsocts.Location = new System.Drawing.Point(171, 0); this.knud_RodentsInsocts.Maximum = new decimal(new int[] { 200, 0, @@ -1681,7 +1638,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_RodentsInsocts.Name = "knud_RodentsInsocts"; this.knud_RodentsInsocts.ReadOnly = true; - this.knud_RodentsInsocts.Size = new System.Drawing.Size(54, 25); + this.knud_RodentsInsocts.Size = new System.Drawing.Size(56, 25); this.knud_RodentsInsocts.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_RodentsInsocts.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_RodentsInsocts.TabIndex = 3; @@ -1697,14 +1654,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_RodentsInsocts_1.Values.Text = "-1"; this.kbtn_RodentsInsocts_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel13 - // - this.kryptonPanel13.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel13.Location = new System.Drawing.Point(0, 114); - this.kryptonPanel13.Name = "kryptonPanel13"; - this.kryptonPanel13.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel13.TabIndex = 6; - // // kryptonPanel14 // this.kryptonPanel14.Controls.Add(this.kryptonWrapLabel8); @@ -1712,7 +1661,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel14.Controls.Add(this.knud_DirtMudGrass); this.kryptonPanel14.Controls.Add(this.kbtn_DirtMudGrass_1); this.kryptonPanel14.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel14.Location = new System.Drawing.Point(0, 89); + this.kryptonPanel14.Location = new System.Drawing.Point(0, 75); this.kryptonPanel14.Name = "kryptonPanel14"; this.kryptonPanel14.Size = new System.Drawing.Size(255, 25); this.kryptonPanel14.TabIndex = 5; @@ -1726,7 +1675,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel8.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel8.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel8.Name = "kryptonWrapLabel8"; - this.kryptonWrapLabel8.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel8.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel8.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel8.Text = "土、泥、草"; this.kryptonWrapLabel8.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1734,7 +1683,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_DirtMudGrass // this.kbtn_DirtMudGrass.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_DirtMudGrass.Location = new System.Drawing.Point(145, 0); + this.kbtn_DirtMudGrass.Location = new System.Drawing.Point(143, 0); this.kbtn_DirtMudGrass.Name = "kbtn_DirtMudGrass"; this.kbtn_DirtMudGrass.Size = new System.Drawing.Size(28, 25); this.kbtn_DirtMudGrass.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1746,7 +1695,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_DirtMudGrass.Dock = System.Windows.Forms.DockStyle.Right; this.knud_DirtMudGrass.Enabled = false; - this.knud_DirtMudGrass.Location = new System.Drawing.Point(173, 0); + this.knud_DirtMudGrass.Location = new System.Drawing.Point(171, 0); this.knud_DirtMudGrass.Maximum = new decimal(new int[] { 200, 0, @@ -1754,7 +1703,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_DirtMudGrass.Name = "knud_DirtMudGrass"; this.knud_DirtMudGrass.ReadOnly = true; - this.knud_DirtMudGrass.Size = new System.Drawing.Size(54, 25); + this.knud_DirtMudGrass.Size = new System.Drawing.Size(56, 25); this.knud_DirtMudGrass.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_DirtMudGrass.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_DirtMudGrass.TabIndex = 3; @@ -1770,14 +1719,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_DirtMudGrass_1.Values.Text = "-1"; this.kbtn_DirtMudGrass_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel11 - // - this.kryptonPanel11.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel11.Location = new System.Drawing.Point(0, 82); - this.kryptonPanel11.Name = "kryptonPanel11"; - this.kryptonPanel11.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel11.TabIndex = 4; - // // kryptonPanel12 // this.kryptonPanel12.Controls.Add(this.kryptonWrapLabel7); @@ -1785,7 +1726,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel12.Controls.Add(this.knud_MetalShaving); this.kryptonPanel12.Controls.Add(this.kbtn_MetalShaving_1); this.kryptonPanel12.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel12.Location = new System.Drawing.Point(0, 57); + this.kryptonPanel12.Location = new System.Drawing.Point(0, 50); this.kryptonPanel12.Name = "kryptonPanel12"; this.kryptonPanel12.Size = new System.Drawing.Size(255, 25); this.kryptonPanel12.TabIndex = 3; @@ -1799,7 +1740,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel7.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel7.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel7.Name = "kryptonWrapLabel7"; - this.kryptonWrapLabel7.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel7.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel7.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel7.Text = "金属刨花"; this.kryptonWrapLabel7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1807,7 +1748,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_MetalShaving // this.kbtn_MetalShaving.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_MetalShaving.Location = new System.Drawing.Point(145, 0); + this.kbtn_MetalShaving.Location = new System.Drawing.Point(143, 0); this.kbtn_MetalShaving.Name = "kbtn_MetalShaving"; this.kbtn_MetalShaving.Size = new System.Drawing.Size(28, 25); this.kbtn_MetalShaving.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1819,7 +1760,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_MetalShaving.Dock = System.Windows.Forms.DockStyle.Right; this.knud_MetalShaving.Enabled = false; - this.knud_MetalShaving.Location = new System.Drawing.Point(173, 0); + this.knud_MetalShaving.Location = new System.Drawing.Point(171, 0); this.knud_MetalShaving.Maximum = new decimal(new int[] { 200, 0, @@ -1827,7 +1768,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_MetalShaving.Name = "knud_MetalShaving"; this.knud_MetalShaving.ReadOnly = true; - this.knud_MetalShaving.Size = new System.Drawing.Size(54, 25); + this.knud_MetalShaving.Size = new System.Drawing.Size(56, 25); this.knud_MetalShaving.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_MetalShaving.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_MetalShaving.TabIndex = 3; @@ -1843,14 +1784,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_MetalShaving_1.Values.Text = "-1"; this.kbtn_MetalShaving_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel10 - // - this.kryptonPanel10.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel10.Location = new System.Drawing.Point(0, 50); - this.kryptonPanel10.Name = "kryptonPanel10"; - this.kryptonPanel10.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel10.TabIndex = 2; - // // kryptonPanel9 // this.kryptonPanel9.Controls.Add(this.kryptonWrapLabel6); @@ -1872,7 +1805,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel6.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel6.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel6.Name = "kryptonWrapLabel6"; - this.kryptonWrapLabel6.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel6.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel6.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel6.Text = "玻璃/木屑"; this.kryptonWrapLabel6.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1880,7 +1813,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_GlassOrWoodShreds // this.kbtn_GlassOrWoodShreds.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_GlassOrWoodShreds.Location = new System.Drawing.Point(145, 0); + this.kbtn_GlassOrWoodShreds.Location = new System.Drawing.Point(143, 0); this.kbtn_GlassOrWoodShreds.Name = "kbtn_GlassOrWoodShreds"; this.kbtn_GlassOrWoodShreds.Size = new System.Drawing.Size(28, 25); this.kbtn_GlassOrWoodShreds.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -1892,7 +1825,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_GlassOrWoodShreds.Dock = System.Windows.Forms.DockStyle.Right; this.knud_GlassOrWoodShreds.Enabled = false; - this.knud_GlassOrWoodShreds.Location = new System.Drawing.Point(173, 0); + this.knud_GlassOrWoodShreds.Location = new System.Drawing.Point(171, 0); this.knud_GlassOrWoodShreds.Maximum = new decimal(new int[] { 200, 0, @@ -1900,7 +1833,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_GlassOrWoodShreds.Name = "knud_GlassOrWoodShreds"; this.knud_GlassOrWoodShreds.ReadOnly = true; - this.knud_GlassOrWoodShreds.Size = new System.Drawing.Size(54, 25); + this.knud_GlassOrWoodShreds.Size = new System.Drawing.Size(56, 25); this.knud_GlassOrWoodShreds.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_GlassOrWoodShreds.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_GlassOrWoodShreds.TabIndex = 3; @@ -1952,7 +1885,8 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonPanel23); this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonPanel39); this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonPanel8); - this.kryptonGroupBox4.Size = new System.Drawing.Size(261, 270); + this.kryptonGroupBox4.Panel.Controls.Add(this.kryptonButton1); + this.kryptonGroupBox4.Size = new System.Drawing.Size(261, 207); this.kryptonGroupBox4.TabIndex = 2; this.kryptonGroupBox4.Values.Heading = ""; // @@ -1985,7 +1919,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel19.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel19.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel19.Name = "kryptonWrapLabel19"; - this.kryptonWrapLabel19.Size = new System.Drawing.Size(147, 25); + this.kryptonWrapLabel19.Size = new System.Drawing.Size(145, 25); this.kryptonWrapLabel19.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel19.Text = "其它污染"; this.kryptonWrapLabel19.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -1993,7 +1927,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_Others // this.kbtn_Others.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_Others.Location = new System.Drawing.Point(147, 0); + this.kbtn_Others.Location = new System.Drawing.Point(145, 0); this.kbtn_Others.Name = "kbtn_Others"; this.kbtn_Others.Size = new System.Drawing.Size(28, 25); this.kbtn_Others.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -2005,7 +1939,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_Others.Dock = System.Windows.Forms.DockStyle.Right; this.knud_Others.Enabled = false; - this.knud_Others.Location = new System.Drawing.Point(175, 0); + this.knud_Others.Location = new System.Drawing.Point(173, 0); this.knud_Others.Maximum = new decimal(new int[] { 200, 0, @@ -2013,7 +1947,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_Others.Name = "knud_Others"; this.knud_Others.ReadOnly = true; - this.knud_Others.Size = new System.Drawing.Size(54, 25); + this.knud_Others.Size = new System.Drawing.Size(56, 25); this.knud_Others.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_Others.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_Others.TabIndex = 3; @@ -2062,27 +1996,15 @@ namespace CleanMachineHMI.FrmUserControl // // kryptonGroupBox3.Panel // - this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel31); this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel32); - this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel29); this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel30); - this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel27); this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel28); - this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel25); this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel26); this.kryptonGroupBox3.Panel.Controls.Add(this.kryptonPanel7); - this.kryptonGroupBox3.Size = new System.Drawing.Size(259, 270); + this.kryptonGroupBox3.Size = new System.Drawing.Size(259, 207); this.kryptonGroupBox3.TabIndex = 1; this.kryptonGroupBox3.Values.Heading = ""; // - // kryptonPanel31 - // - this.kryptonPanel31.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel31.Location = new System.Drawing.Point(0, 146); - this.kryptonPanel31.Name = "kryptonPanel31"; - this.kryptonPanel31.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel31.TabIndex = 10; - // // kryptonPanel32 // this.kryptonPanel32.Controls.Add(this.kryptonWrapLabel17); @@ -2090,7 +2012,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel32.Controls.Add(this.knud_Mold); this.kryptonPanel32.Controls.Add(this.kbtn_Mold_1); this.kryptonPanel32.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel32.Location = new System.Drawing.Point(0, 121); + this.kryptonPanel32.Location = new System.Drawing.Point(0, 100); this.kryptonPanel32.Name = "kryptonPanel32"; this.kryptonPanel32.Size = new System.Drawing.Size(255, 25); this.kryptonPanel32.TabIndex = 9; @@ -2104,7 +2026,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel17.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel17.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel17.Name = "kryptonWrapLabel17"; - this.kryptonWrapLabel17.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel17.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel17.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel17.Text = "霉菌"; this.kryptonWrapLabel17.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -2112,7 +2034,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_Mold // this.kbtn_Mold.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_Mold.Location = new System.Drawing.Point(145, 0); + this.kbtn_Mold.Location = new System.Drawing.Point(143, 0); this.kbtn_Mold.Name = "kbtn_Mold"; this.kbtn_Mold.Size = new System.Drawing.Size(28, 25); this.kbtn_Mold.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -2124,7 +2046,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_Mold.Dock = System.Windows.Forms.DockStyle.Right; this.knud_Mold.Enabled = false; - this.knud_Mold.Location = new System.Drawing.Point(173, 0); + this.knud_Mold.Location = new System.Drawing.Point(171, 0); this.knud_Mold.Maximum = new decimal(new int[] { 200, 0, @@ -2132,7 +2054,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_Mold.Name = "knud_Mold"; this.knud_Mold.ReadOnly = true; - this.knud_Mold.Size = new System.Drawing.Size(54, 25); + this.knud_Mold.Size = new System.Drawing.Size(56, 25); this.knud_Mold.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_Mold.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_Mold.TabIndex = 3; @@ -2148,14 +2070,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_Mold_1.Values.Text = "-1"; this.kbtn_Mold_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel29 - // - this.kryptonPanel29.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel29.Location = new System.Drawing.Point(0, 114); - this.kryptonPanel29.Name = "kryptonPanel29"; - this.kryptonPanel29.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel29.TabIndex = 8; - // // kryptonPanel30 // this.kryptonPanel30.Controls.Add(this.kryptonWrapLabel16); @@ -2163,7 +2077,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel30.Controls.Add(this.knud_OdorOrAtypicalSmell); this.kryptonPanel30.Controls.Add(this.kbtn_OdorOrAtypicalSmell_1); this.kryptonPanel30.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel30.Location = new System.Drawing.Point(0, 89); + this.kryptonPanel30.Location = new System.Drawing.Point(0, 75); this.kryptonPanel30.Name = "kryptonPanel30"; this.kryptonPanel30.Size = new System.Drawing.Size(255, 25); this.kryptonPanel30.TabIndex = 7; @@ -2177,7 +2091,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel16.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel16.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel16.Name = "kryptonWrapLabel16"; - this.kryptonWrapLabel16.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel16.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel16.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel16.Text = "臭味或异味"; this.kryptonWrapLabel16.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -2185,7 +2099,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_OdorOrAtypicalSmell // this.kbtn_OdorOrAtypicalSmell.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_OdorOrAtypicalSmell.Location = new System.Drawing.Point(145, 0); + this.kbtn_OdorOrAtypicalSmell.Location = new System.Drawing.Point(143, 0); this.kbtn_OdorOrAtypicalSmell.Name = "kbtn_OdorOrAtypicalSmell"; this.kbtn_OdorOrAtypicalSmell.Size = new System.Drawing.Size(28, 25); this.kbtn_OdorOrAtypicalSmell.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -2197,7 +2111,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_OdorOrAtypicalSmell.Dock = System.Windows.Forms.DockStyle.Right; this.knud_OdorOrAtypicalSmell.Enabled = false; - this.knud_OdorOrAtypicalSmell.Location = new System.Drawing.Point(173, 0); + this.knud_OdorOrAtypicalSmell.Location = new System.Drawing.Point(171, 0); this.knud_OdorOrAtypicalSmell.Maximum = new decimal(new int[] { 200, 0, @@ -2205,7 +2119,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_OdorOrAtypicalSmell.Name = "knud_OdorOrAtypicalSmell"; this.knud_OdorOrAtypicalSmell.ReadOnly = true; - this.knud_OdorOrAtypicalSmell.Size = new System.Drawing.Size(54, 25); + this.knud_OdorOrAtypicalSmell.Size = new System.Drawing.Size(56, 25); this.knud_OdorOrAtypicalSmell.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_OdorOrAtypicalSmell.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_OdorOrAtypicalSmell.TabIndex = 3; @@ -2221,14 +2135,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_OdorOrAtypicalSmell_1.Values.Text = "-1"; this.kbtn_OdorOrAtypicalSmell_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel27 - // - this.kryptonPanel27.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel27.Location = new System.Drawing.Point(0, 82); - this.kryptonPanel27.Name = "kryptonPanel27"; - this.kryptonPanel27.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel27.TabIndex = 6; - // // kryptonPanel28 // this.kryptonPanel28.Controls.Add(this.kryptonWrapLabel15); @@ -2236,7 +2142,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonPanel28.Controls.Add(this.knud_FecesExcreta); this.kryptonPanel28.Controls.Add(this.kbtn_FecesExcreta_1); this.kryptonPanel28.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel28.Location = new System.Drawing.Point(0, 57); + this.kryptonPanel28.Location = new System.Drawing.Point(0, 50); this.kryptonPanel28.Name = "kryptonPanel28"; this.kryptonPanel28.Size = new System.Drawing.Size(255, 25); this.kryptonPanel28.TabIndex = 5; @@ -2250,7 +2156,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel15.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel15.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel15.Name = "kryptonWrapLabel15"; - this.kryptonWrapLabel15.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel15.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel15.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel15.Text = "粪便、排泄物"; this.kryptonWrapLabel15.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -2258,7 +2164,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_FecesExcreta // this.kbtn_FecesExcreta.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_FecesExcreta.Location = new System.Drawing.Point(145, 0); + this.kbtn_FecesExcreta.Location = new System.Drawing.Point(143, 0); this.kbtn_FecesExcreta.Name = "kbtn_FecesExcreta"; this.kbtn_FecesExcreta.Size = new System.Drawing.Size(28, 25); this.kbtn_FecesExcreta.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -2270,7 +2176,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_FecesExcreta.Dock = System.Windows.Forms.DockStyle.Right; this.knud_FecesExcreta.Enabled = false; - this.knud_FecesExcreta.Location = new System.Drawing.Point(173, 0); + this.knud_FecesExcreta.Location = new System.Drawing.Point(171, 0); this.knud_FecesExcreta.Maximum = new decimal(new int[] { 200, 0, @@ -2278,7 +2184,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_FecesExcreta.Name = "knud_FecesExcreta"; this.knud_FecesExcreta.ReadOnly = true; - this.knud_FecesExcreta.Size = new System.Drawing.Size(54, 25); + this.knud_FecesExcreta.Size = new System.Drawing.Size(56, 25); this.knud_FecesExcreta.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_FecesExcreta.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_FecesExcreta.TabIndex = 3; @@ -2294,14 +2200,6 @@ namespace CleanMachineHMI.FrmUserControl this.kbtn_FecesExcreta_1.Values.Text = "-1"; this.kbtn_FecesExcreta_1.Click += new System.EventHandler(this.kbtn_GlassOrWoodShreds_1_Click); // - // kryptonPanel25 - // - this.kryptonPanel25.Dock = System.Windows.Forms.DockStyle.Top; - this.kryptonPanel25.Location = new System.Drawing.Point(0, 50); - this.kryptonPanel25.Name = "kryptonPanel25"; - this.kryptonPanel25.Size = new System.Drawing.Size(255, 7); - this.kryptonPanel25.TabIndex = 4; - // // kryptonPanel26 // this.kryptonPanel26.Controls.Add(this.kryptonWrapLabel14); @@ -2323,7 +2221,7 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonWrapLabel14.LabelStyle = Krypton.Toolkit.LabelStyle.NormalControl; this.kryptonWrapLabel14.Location = new System.Drawing.Point(0, 0); this.kryptonWrapLabel14.Name = "kryptonWrapLabel14"; - this.kryptonWrapLabel14.Size = new System.Drawing.Size(145, 25); + this.kryptonWrapLabel14.Size = new System.Drawing.Size(143, 25); this.kryptonWrapLabel14.StateCommon.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.kryptonWrapLabel14.Text = "有湿气或受潮"; this.kryptonWrapLabel14.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; @@ -2331,7 +2229,7 @@ namespace CleanMachineHMI.FrmUserControl // kbtn_MoistureOrWet // this.kbtn_MoistureOrWet.Dock = System.Windows.Forms.DockStyle.Right; - this.kbtn_MoistureOrWet.Location = new System.Drawing.Point(145, 0); + this.kbtn_MoistureOrWet.Location = new System.Drawing.Point(143, 0); this.kbtn_MoistureOrWet.Name = "kbtn_MoistureOrWet"; this.kbtn_MoistureOrWet.Size = new System.Drawing.Size(28, 25); this.kbtn_MoistureOrWet.StateCommon.Content.ShortText.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); @@ -2343,7 +2241,7 @@ namespace CleanMachineHMI.FrmUserControl // this.knud_MoistureOrWet.Dock = System.Windows.Forms.DockStyle.Right; this.knud_MoistureOrWet.Enabled = false; - this.knud_MoistureOrWet.Location = new System.Drawing.Point(173, 0); + this.knud_MoistureOrWet.Location = new System.Drawing.Point(171, 0); this.knud_MoistureOrWet.Maximum = new decimal(new int[] { 200, 0, @@ -2351,7 +2249,7 @@ namespace CleanMachineHMI.FrmUserControl 0}); this.knud_MoistureOrWet.Name = "knud_MoistureOrWet"; this.knud_MoistureOrWet.ReadOnly = true; - this.knud_MoistureOrWet.Size = new System.Drawing.Size(54, 25); + this.knud_MoistureOrWet.Size = new System.Drawing.Size(56, 25); this.knud_MoistureOrWet.StateCommon.Content.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.knud_MoistureOrWet.StateDisabled.Back.Color1 = System.Drawing.Color.White; this.knud_MoistureOrWet.TabIndex = 3; @@ -2795,16 +2693,12 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox5.Panel.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox5)).EndInit(); this.kryptonGroupBox5.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.dwqeqw)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel24)).EndInit(); this.kryptonPanel24.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel21)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel22)).EndInit(); this.kryptonPanel22.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel19)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel20)).EndInit(); this.kryptonPanel20.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel17)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel18)).EndInit(); this.kryptonPanel18.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel6)).EndInit(); @@ -2816,19 +2710,14 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox2.Panel.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox2)).EndInit(); this.kryptonGroupBox2.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel4)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel33)).EndInit(); this.kryptonPanel33.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel15)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel16)).EndInit(); this.kryptonPanel16.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel13)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel14)).EndInit(); this.kryptonPanel14.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel11)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel12)).EndInit(); this.kryptonPanel12.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel10)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel9)).EndInit(); this.kryptonPanel9.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel5)).EndInit(); @@ -2846,16 +2735,12 @@ namespace CleanMachineHMI.FrmUserControl this.kryptonGroupBox3.Panel.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.kryptonGroupBox3)).EndInit(); this.kryptonGroupBox3.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel31)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel32)).EndInit(); this.kryptonPanel32.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel29)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel30)).EndInit(); this.kryptonPanel30.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel27)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel28)).EndInit(); this.kryptonPanel28.ResumeLayout(false); - ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel25)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel26)).EndInit(); this.kryptonPanel26.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.kryptonPanel7)).EndInit(); @@ -2930,25 +2815,21 @@ namespace CleanMachineHMI.FrmUserControl private Krypton.Toolkit.KryptonLabel kryptonLabel1; private Krypton.Toolkit.KryptonLabel kryptonLabel2; private Krypton.Toolkit.KryptonGroupBox kryptonGroupBox5; - private Krypton.Toolkit.KryptonPanel dwqeqw; private Krypton.Toolkit.KryptonPanel kryptonPanel24; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel13; private Krypton.Toolkit.KryptonButton kbtn_Adhesives; private Krypton.Toolkit.KryptonNumericUpDown knud_Adhesives; private Krypton.Toolkit.KryptonButton kbtn_Adhesives_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel21; private Krypton.Toolkit.KryptonPanel kryptonPanel22; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel12; private Krypton.Toolkit.KryptonButton kbtn_Solvents; private Krypton.Toolkit.KryptonNumericUpDown knud_Solvents; private Krypton.Toolkit.KryptonButton kbtn_Solvents_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel19; private Krypton.Toolkit.KryptonPanel kryptonPanel20; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel11; private Krypton.Toolkit.KryptonButton kbtn_StrongOdor; private Krypton.Toolkit.KryptonNumericUpDown knud_StrongOdor; private Krypton.Toolkit.KryptonButton kbtn_StrongOdor_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel17; private Krypton.Toolkit.KryptonPanel kryptonPanel18; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel10; private Krypton.Toolkit.KryptonButton kbtn_OilOrGreaseOrPaint; @@ -2959,31 +2840,26 @@ namespace CleanMachineHMI.FrmUserControl private Krypton.Toolkit.KryptonPanel kryptonPanel3; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; private Krypton.Toolkit.KryptonGroupBox kryptonGroupBox2; - private Krypton.Toolkit.KryptonPanel kryptonPanel4; private Krypton.Toolkit.KryptonPanel kryptonPanel33; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel21; private Krypton.Toolkit.KryptonButton kbtn_TapeOrStickers; private Krypton.Toolkit.KryptonNumericUpDown knud_TapeOrStickers; private Krypton.Toolkit.KryptonButton kbtn_TapeOrStickers_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel15; private Krypton.Toolkit.KryptonPanel kryptonPanel16; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel9; private Krypton.Toolkit.KryptonButton kbtn_RodentsInsocts; private Krypton.Toolkit.KryptonNumericUpDown knud_RodentsInsocts; private Krypton.Toolkit.KryptonButton kbtn_RodentsInsocts_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel13; private Krypton.Toolkit.KryptonPanel kryptonPanel14; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel8; private Krypton.Toolkit.KryptonButton kbtn_DirtMudGrass; private Krypton.Toolkit.KryptonNumericUpDown knud_DirtMudGrass; private Krypton.Toolkit.KryptonButton kbtn_DirtMudGrass_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel11; private Krypton.Toolkit.KryptonPanel kryptonPanel12; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel7; private Krypton.Toolkit.KryptonButton kbtn_MetalShaving; private Krypton.Toolkit.KryptonNumericUpDown knud_MetalShaving; private Krypton.Toolkit.KryptonButton kbtn_MetalShaving_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel10; private Krypton.Toolkit.KryptonPanel kryptonPanel9; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel6; private Krypton.Toolkit.KryptonButton kbtn_GlassOrWoodShreds; @@ -3001,25 +2877,21 @@ namespace CleanMachineHMI.FrmUserControl private Krypton.Toolkit.KryptonPanel kryptonPanel8; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel5; private Krypton.Toolkit.KryptonGroupBox kryptonGroupBox3; - private Krypton.Toolkit.KryptonPanel kryptonPanel31; private Krypton.Toolkit.KryptonPanel kryptonPanel32; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel17; private Krypton.Toolkit.KryptonButton kbtn_Mold; private Krypton.Toolkit.KryptonNumericUpDown knud_Mold; private Krypton.Toolkit.KryptonButton kbtn_Mold_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel29; private Krypton.Toolkit.KryptonPanel kryptonPanel30; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel16; private Krypton.Toolkit.KryptonButton kbtn_OdorOrAtypicalSmell; private Krypton.Toolkit.KryptonNumericUpDown knud_OdorOrAtypicalSmell; private Krypton.Toolkit.KryptonButton kbtn_OdorOrAtypicalSmell_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel27; private Krypton.Toolkit.KryptonPanel kryptonPanel28; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel15; private Krypton.Toolkit.KryptonButton kbtn_FecesExcreta; private Krypton.Toolkit.KryptonNumericUpDown knud_FecesExcreta; private Krypton.Toolkit.KryptonButton kbtn_FecesExcreta_1; - private Krypton.Toolkit.KryptonPanel kryptonPanel25; private Krypton.Toolkit.KryptonPanel kryptonPanel26; private Krypton.Toolkit.KryptonWrapLabel kryptonWrapLabel14; private Krypton.Toolkit.KryptonButton kbtn_MoistureOrWet; @@ -3045,5 +2917,8 @@ namespace CleanMachineHMI.FrmUserControl private Krypton.Toolkit.KryptonLabel kryptonLabel14; private Krypton.Toolkit.KryptonTextBox knud_WorkedFullPalletNum; private Krypton.Toolkit.KryptonButton kryptonButton2; + private Krypton.Toolkit.KryptonButton kryptonButton8; + private Krypton.Toolkit.KryptonTextBox ktb_ShiftCount; + private Krypton.Toolkit.KryptonLabel kryptonLabel16; } } diff --git a/CleanMachineHMI/FrmUserControl/frmMainDetail.cs b/CleanMachineHMI/FrmUserControl/frmMainDetail.cs index ba7391e..2003e7f 100644 --- a/CleanMachineHMI/FrmUserControl/frmMainDetail.cs +++ b/CleanMachineHMI/FrmUserControl/frmMainDetail.cs @@ -1,4 +1,7 @@ -using CleanMachineHMI.Domain.Enums; + +//#define NewFun + +using CleanMachineHMI.Domain.Enums; using CleanMachineHMI.Utils; using Krypton.Toolkit; using FastReport; @@ -17,6 +20,8 @@ using System.Threading.Tasks; using System.Windows.Forms; using CleanMachine.Model.BAS; + + namespace CleanMachineHMI.FrmUserControl { [FormType(EnumFormType.MainDetail)] @@ -25,10 +30,10 @@ namespace CleanMachineHMI.FrmUserControl public frmMainDetail() { InitializeComponent(); - + } - + private List basCleanTypeMsgList = new List(); @@ -37,6 +42,7 @@ namespace CleanMachineHMI.FrmUserControl /// private string _reportFolder = Application.StartupPath + "\\ReportMd\\"; public delegate void dlgCleanCurrentWorkingData(); + public static dlgCleanCurrentWorkingData RefreshCurrentWorkingDataFrmHost; private int _lastPaltteRemain = 0; @@ -175,14 +181,16 @@ namespace CleanMachineHMI.FrmUserControl //加载当前工作信息 LoadCurrentWorkingTray(); - +#if NewFun PlcOperationHelper.Instance.OnReadFinish += Instance_OnReadFinish; - //Thread th1 = new Thread(MainDtlRunTh) - //{ - // IsBackground = true - //}; - //th1.Start(); +#else + Thread th1 = new Thread(MainDtlRunTh) + { + IsBackground = true + }; + th1.Start(); +#endif foreach (Control item in panMenu.Controls) { @@ -273,14 +281,14 @@ namespace CleanMachineHMI.FrmUserControl // swtbtn_fullPalletMod.L_IsOpen = false; // // { - // kryptonLabel12.Text = "Count Full"; + // kryptonLabel12.Text = "Count Full"; // } // else // { // kryptonLabel12.Text = "计数满料"; // } //} - // knud_WorkedFullPalletNum.Text = PlcOperationHelper.Instance.ReadPlcItem("WorkedFullPalletNum", PlcItemTypeDesc.D).ToString(); + // knud_WorkedFullPalletNum.Text = PlcOperationHelper.Instance.ReadPlcItem("WorkedFullPalletNum", PlcItemTypeDesc.D).ToString(); knud_WorkedFullPalletNum.Text = PlcOperationHelper.Instance.ReadPlcItem("WorkedFullPalletNum").ToString(); @@ -310,59 +318,168 @@ namespace CleanMachineHMI.FrmUserControl } } + + + private void FinishWorkingPallet1() + { + +#if RELEASE + try + { +#endif + //满料标识 + bool isFinishWorkingPallet = Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("FinishWorkingPallet", PlcItemTypeDesc.M)); + //ToDo: 根据满料的方式,增加相应的满料判断代码 + bool fullPalletMode = Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("FullPalletMode", PlcItemTypeDesc.M)); + + int countFullNum = Convert.ToInt32(PlcOperationHelper.Instance.ReadPlcItem("WorkedFullPalletNum", PlcItemTypeDesc.D)); + //是否强制满料 + bool isForceFullPallet = Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("ForceFullPallet", PlcItemTypeDesc.M)); + + string sql_CurrPalletmsg = $@"SELECT * FROM CM_WORKING_PALLET WHERE WORKING_STATUS = 0"; + DataTable dt_CurrPalletmsg = LeadDbHelperSQLite.Query(sql_CurrPalletmsg).Tables[0]; + + if (fullPalletMode)// 延时满料 + { + //if (dt_CurrPalletmsg != null && dt_CurrPalletmsg.Rows.Count > 0 && isFinishWorkingPallet) + //{ + // string palletCodeMsg = dt_CurrPalletmsg.Rows[0]["WORKING_PALLET_CODE"].ToString(); + // LogHelper.WriteLog($"作业托盘:【{palletCodeMsg}】,开始处理延时满料业务。", LogTypeEum.Run); + // string sqlWorkingIrMsg = $@"SELECT DISTINCT IR_CODE FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{palletCodeMsg}'"; + + // DataTable dt_workingIrMsg = LeadDbHelperSQLite.Query(sqlWorkingIrMsg).Tables[0]; + // if (dt_workingIrMsg != null && dt_workingIrMsg.Rows.Count > 0) + // { + // PrintPalletData(dt_workingIrMsg, palletCodeMsg); + // LogHelper.WriteLog($"作业托盘:【{palletCodeMsg}】,延时满料业务处理完成,数据打印完成。", LogTypeEum.Run); + // } + //} + } + else //计数满料 + { + if (dt_CurrPalletmsg != null && dt_CurrPalletmsg.Rows.Count > 0) + { + string palletCodeMsg = dt_CurrPalletmsg.Rows[0]["WORKING_PALLET_CODE"].ToString(); + string sqlCurrNumMsg = $@"SELECT ifnull(SUM(CURRENT_NUMBER),0) FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{palletCodeMsg}' and CLEAN_MODE_CODE = 'SortedCleaned'"; + DataTable dt_CurrNumMsg = LeadDbHelperSQLite.Query(sqlCurrNumMsg).Tables[0]; + if (dt_CurrNumMsg != null && dt_CurrNumMsg.Rows.Count > 0) + { + //这个值只包含托盘在这个IR下个数量 + int currentNum = Convert.ToInt32(dt_CurrNumMsg.Rows[0][0]); + + currentNum += this.lastPaltteRemain; + + string sqlWorkingIrMsg = $@"SELECT DISTINCT IR_CODE FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{palletCodeMsg}'"; + DataTable dt_workingIrMsg = LeadDbHelperSQLite.Query(sqlWorkingIrMsg).Tables[0]; + if (currentNum >= countFullNum && isFinishWorkingPallet && countFullNum > 0) //正常满料 + { + LogHelper.WriteLog($"作业托盘:【{palletCodeMsg}】,开始处理计数满料业务。满料方式:【正常满料】", LogTypeEum.Run); + if (dt_workingIrMsg != null && dt_workingIrMsg.Rows.Count > 0) + PrintPalletData(dt_workingIrMsg.Rows[0][0].ToString(), palletCodeMsg, false); + LogHelper.WriteLog($"作业托盘:【{palletCodeMsg}】,计数满料业务正常处理完成,数据打印完成。", LogTypeEum.Run); + + } + else if (currentNum < countFullNum && isFinishWorkingPallet && isForceFullPallet && countFullNum > 0)//强制满料 + { + LogHelper.WriteLog($"作业托盘:【{palletCodeMsg}】,开始处理计数满料业务。满料方式:【强制满料】", LogTypeEum.Run); + if (dt_workingIrMsg != null && dt_workingIrMsg.Rows.Count > 0) + PrintPalletData(dt_workingIrMsg.Rows[0][0].ToString(), palletCodeMsg, true); + LogHelper.WriteLog($"作业托盘:【{palletCodeMsg}】,计数满料业务强制处理完成,数据打印完成。", LogTypeEum.Run); + + } + } + } + } + + if (!isFinishWorkingPallet) + { + + string sql = $@"select * from CM_WORKING_PALLET where WORKING_STATUS = '-1'"; + DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0]; + if (dt != null && dt.Rows.Count > 0) + { + string sql1 = $@"Update CM_WORKING_PALLET set WORKING_STATUS = 0 where WORKING_STATUS = '-1'"; + string sql2 = $@"Update CM_WORKING_PALLET_DTL set WORKING_DTL_STATUS = 0 where WORKING_DTL_STATUS = '-1'"; + LeadDbHelperSQLite.ExecuteSql(sql1); + LeadDbHelperSQLite.ExecuteSql(sql2); + + //污染类型操作禁用 + //kryptonGroupBox10.Enabled = false; + kryptonGroupBox2.Enabled = true; + kryptonGroupBox3.Enabled = true; + kryptonGroupBox4.Enabled = true; + kryptonGroupBox5.Enabled = true; + kbtn_Scrap.Enabled = true; + kbtn_Scrap_1.Enabled = true; + kbtn_forceFinish.Enabled = true; + + + } + } +#if RELEASE + } + catch (Exception ex) + { + LogHelper.WriteLog($"~~~~~~~~~~~~~~托盘结束发生异常!【{ex.Message}】。~~~~~~~~~~~~~~", LogTypeEum.Run); + } +#endif + } + + + private void Instance_OnReadFinish() { if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("CleanMacRunStatusNew", PlcItemTypeDesc.M))) { - cbt_RunStatusTran.BackColor = Color.Lime; + cbt_RunStatusTran.BackColor = Color.Lime; } else { - cbt_RunStatusTran.BackColor = Color.Gray; + cbt_RunStatusTran.BackColor = Color.Gray; } //毛刷1运行状态 if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush1Selection", PlcItemTypeDesc.M))) { - - cbt_Brush1StatusTran.BackColor = Color.Lime; - + + cbt_Brush1StatusTran.BackColor = Color.Lime; + } else { - - cbt_Brush1StatusTran.BackColor = Color.Gray; - + + cbt_Brush1StatusTran.BackColor = Color.Gray; + } //毛刷2启用状态 if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush2Selection", PlcItemTypeDesc.M))) { - - cbt_Brush2StatusTran.BackColor = Color.Lime; - - } - else - { - - cbt_Brush2StatusTran.BackColor = Color.Gray; - - } - //毛刷3启用状态 - if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush3Selection", PlcItemTypeDesc.M))) - { - - cbt_Brush3StatusTran.BackColor = Color.Lime; - + + cbt_Brush2StatusTran.BackColor = Color.Lime; + } else { - - cbt_Brush3StatusTran.BackColor = Color.Gray; - + cbt_Brush2StatusTran.BackColor = Color.Gray; + + } + //毛刷3启用状态 + if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("Hairbrush3Selection", PlcItemTypeDesc.M))) + { + + cbt_Brush3StatusTran.BackColor = Color.Lime; + + } + else + { + + + cbt_Brush3StatusTran.BackColor = Color.Gray; + } //喷头选择状态 //if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("NozzleSelection", PlcItemTypeDesc.M))) @@ -383,15 +500,15 @@ namespace CleanMachineHMI.FrmUserControl if (Convert.ToBoolean(PlcOperationHelper.Instance.ReadPlcItem("StaticbarsSel", PlcItemTypeDesc.M))) { - - cbt_staticbar.BackColor = Color.Lime; - + + cbt_staticbar.BackColor = Color.Lime; + } else { - - cbt_staticbar.BackColor = Color.Gray; - + + cbt_staticbar.BackColor = Color.Gray; + } //计数模式选择 @@ -410,6 +527,8 @@ namespace CleanMachineHMI.FrmUserControl // })); //} + + //显示托盘编号 if (ktb_IR.Text.Trim().Length > 0) { @@ -417,72 +536,84 @@ namespace CleanMachineHMI.FrmUserControl DataTable dtWorkPalletSel = LeadDbHelperSQLite.Query(sqlWorkPalletSel).Tables[0]; if (dtWorkPalletSel.Rows.Count > 0) { - - ktb_CurrPalletCode.Text = dtWorkPalletSel.Rows[0]["WORKING_PALLET_CODE"].ToString(); - + ktb_CurrPalletCode.Text = dtWorkPalletSel.Rows[0]["WORKING_PALLET_CODE"].ToString(); + + } else { - - ktb_CurrPalletCode.Text = ""; - + ktb_CurrPalletCode.Text = ""; + + } } + + // 显示班次计数 + //ShiftCount + var shiftCount = PlcOperationHelper.Instance.ReadPlcItem("ShiftCount").ToString(); + this.ktb_ShiftCount.Text = shiftCount; + + + string ktb_IRTest = ""; string kcmb_SheetTypeText = ""; string CurrPalletCodeText = ""; - - ktb_IRTest = this.ktb_IR.Text; - kcmb_SheetTypeText = this.kcmb_SheetType.Text; - CurrPalletCodeText = ktb_CurrPalletCode.Text.Trim(); - + ktb_IRTest = this.ktb_IR.Text; + kcmb_SheetTypeText = this.kcmb_SheetType.Text; + CurrPalletCodeText = ktb_CurrPalletCode.Text.Trim(); + // 显示班次计数 + //ShiftCount //防止中途关闭系统产生数据丢失,因此每周期都会更新数据 string sql = $@"SELECT SUM(CURRENT_NUMBER) FROM CM_WORKING_PALLET_DTL WHERE CLEAN_MODE_CODE = 'SortedCleaned' AND IR_CODE = '{ktb_IRTest}' AND SHEET_TYPE_CODE = '{kcmb_SheetTypeText}'"; object obj = LeadDbHelperSQLite.GetSingle(sql); if (obj == null) { - ktb_CompleteNum.Text = "0"; + ktb_CompleteNum.Text = "0"; } else { - ktb_CompleteNum.Text = obj.ToString(); + ktb_CompleteNum.Text = obj.ToString(); } string sql1 = $@"SELECT SUM(CURRENT_NUMBER) FROM CM_WORKING_PALLET_DTL WHERE CLEAN_MODE_CODE <> 'SortedCleaned' AND IR_CODE = '{ktb_IRTest}' AND SHEET_TYPE_CODE = '{kcmb_SheetTypeText}'"; object obj1 = LeadDbHelperSQLite.GetSingle(sql1); if (obj1 == null) { - - ktb_ScrapNum.Text = "0"; - + + ktb_ScrapNum.Text = "0"; + } else { - - ktb_ScrapNum.Text = obj1.ToString(); - + + ktb_ScrapNum.Text = obj1.ToString(); + } string sql11 = $@"SELECT SUM(CURRENT_NUMBER) FROM CM_WORKING_PALLET_DTL WHERE CLEAN_MODE_CODE = 'Scrap' AND IR_CODE = '{ktb_IRTest}' AND SHEET_TYPE_CODE = '{kcmb_SheetTypeText}' AND WORKING_PALLET_CODE = '{CurrPalletCodeText}'"; object obj11 = LeadDbHelperSQLite.GetSingle(sql11); if (obj11 == null) { - - ktb_Scrap.Text = "0"; - + + ktb_Scrap.Text = "0"; + } else { - - ktb_Scrap.Text = obj11.ToString(); - + + ktb_Scrap.Text = obj11.ToString(); + } + + + + string sqlPalletCount = $@"SELECT CURRENT_NUMBER,WORKING_DTL_STATUS FROM CM_WORKING_PALLET_DTL WHERE CLEAN_MODE_CODE = 'SortedCleaned' AND IR_CODE = '{ktb_IRTest}' AND SHEET_TYPE_CODE = '{kcmb_SheetTypeText}'"; DataTable dtPalletCount = LeadDbHelperSQLite.Query(sqlPalletCount).Tables[0]; if (dtPalletCount != null && dtPalletCount.Rows.Count > 0) @@ -500,18 +631,18 @@ namespace CleanMachineHMI.FrmUserControl currentPalletNum += Convert.ToInt32(item["CURRENT_NUMBER"]); } } - - ktb_CurrentPalletNum.Text = currentPalletNum.ToString(); - ktb_FinishedPalletNum.Text = finishedPalletNum.ToString(); - + + ktb_CurrentPalletNum.Text = currentPalletNum.ToString(); + ktb_FinishedPalletNum.Text = finishedPalletNum.ToString(); + } else { - - ktb_CurrentPalletNum.Text = "0"; - ktb_FinishedPalletNum.Text = "0"; - + + ktb_CurrentPalletNum.Text = "0"; + ktb_FinishedPalletNum.Text = "0"; + } //读取PLC当前值-这个值带有初始值 @@ -582,6 +713,8 @@ namespace CleanMachineHMI.FrmUserControl } + FinishWorkingPallet1(); + } private void SyncFinishPalletData(object sender, EventArgs e) @@ -1285,280 +1418,7 @@ namespace CleanMachineHMI.FrmUserControl } private void PrintWorkedIrMsg(string workingIrCodeMsg) { - try - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】自动打印开始。~~~~~~~~~~~~~~", LogTypeEum.Run); - //string sql = $@" - // SELECT - // * - // FROM - // VW_WORKING_PALLET_MSG - // WHERE - // WORKING_PALLET_CODE = '{woringPalletMsg}' - // AND IR_CODE = '{workingIrCodeMsg}' - // "; - string sql = $@" - SELECT - * - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - "; - DataTable dt = LeadDbHelperSQLite.Query(sql).Tables[0]; - if (dt != null && dt.Rows.Count > 0) - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - - string sqlGroup = $@" - SELECT - CONTAMINATION_TYPE_CODE, - CONTAMINATION_DTL_CODE, - SUM(CURRENT_NUMBER) CURRENT_NUMBER - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - GROUP BY - CONTAMINATION_TYPE_CODE, - CONTAMINATION_DTL_CODE - "; - DataTable dtGroup = LeadDbHelperSQLite.Query(sqlGroup).Tables[0]; - - #region 物理污染 - //string sql1 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'PhysicalContamination'"; - //DataTable dt1 = LeadDbHelperSQLite.Query(sql1).Tables[0].Copy(); - - DataRow[] drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'PhysicalContamination'"); - if (drs != null && drs.Length > 0) - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】物理污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - } - else - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】物理污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); - } - DataTable dt1 = new DataTable(); - dt1.Columns.Add("Kind", typeof(string)); - dt1.Columns.Add("Qty", typeof(string)); - foreach (DataRow item in drs) - { - DataRow row = dt1.NewRow(); - row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString(); - row["Qty"] = item["CURRENT_NUMBER"].ToString(); - dt1.Rows.Add(row); - } - dt1.TableName = "Table1"; - #endregion - - #region 化学污染 - //string sql2 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'ChemicalContamination'"; - //DataTable dt2 = LeadDbHelperSQLite.Query(sql2).Tables[0].Copy(); - drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'ChemicalContamination'"); - if (drs != null && drs.Length > 0) - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】化学污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - } - else - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】化学污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); - } - DataTable dt2 = dt1.Clone(); - foreach (DataRow item in drs) - { - DataRow row = dt2.NewRow(); - row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString(); - row["Qty"] = item["CURRENT_NUMBER"].ToString(); - dt2.Rows.Add(row); - } - dt2.TableName = "Table2"; - #endregion - - #region 微生物污染 - //string sql3 = $@"SELECT CONTAMINATION_DTL_CODE Kind,CURRENT_NUMBER Qty FROM VW_WORKING_PALLET_MSG WHERE WORKING_PALLET_CODE = '{woringPalletMsg}' AND IR_CODE = '{workingIrCodeMsg}' AND CONTAMINATION_TYPE_CODE = 'MicrobiologicalContamination'"; - //DataTable dt3 = LeadDbHelperSQLite.Query(sql3).Tables[0].Copy(); - drs = dtGroup.Select(" CONTAMINATION_TYPE_CODE = 'MicrobiologicalContamination'"); - if (drs != null && drs.Length > 0) - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】微生物污染 明细数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - } - else - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】微生物污染 明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); - } - DataTable dt3 = dt1.Clone(); - foreach (DataRow item in drs) - { - DataRow row = dt3.NewRow(); - row["Kind"] = item["CONTAMINATION_DTL_CODE"].ToString(); - row["Qty"] = item["CURRENT_NUMBER"].ToString(); - dt3.Rows.Add(row); - } - dt3.TableName = "Table3"; - #endregion - - string sql4 = $@" - SELECT - C.SHEET_TYPE_CODE Sheets, - SUM(CASE CLEAN_MODE_CODE WHEN 'SortedCleaned' THEN Qty ELSE 0 END) SortedCleaned, - SUM(CASE CLEAN_MODE_CODE WHEN 'SpecialCleaning' THEN Qty ELSE 0 END) SpecialCleaning, - SUM(CASE CLEAN_MODE_CODE WHEN 'Scrap' THEN Qty ELSE 0 END) Scrap, - SUM(CASE CLEAN_MODE_CODE WHEN 'Others' THEN Qty ELSE 0 END) Others, - IFNULL(C.TotalQty, 0) TotalQty - FROM - ( - SELECT - A.SHEET_TYPE_CODE, - B.CLEAN_MODE_CODE, - B.Qty, - C.TotalQty - FROM - BAS_SHEET_TYPE A LEFT JOIN - ( - SELECT - SHEET_TYPE_CODE, - SUM(CURRENT_NUMBER) TotalQty - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - GROUP BY SHEET_TYPE_CODE) C ON A.SHEET_TYPE_CODE = C.SHEET_TYPE_CODE - LEFT JOIN ( - SELECT - SHEET_TYPE_CODE, - CLEAN_MODE_CODE, - SUM(CURRENT_NUMBER) Qty - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - GROUP BY CLEAN_MODE_CODE,SHEET_TYPE_CODE - ) B ON C.SHEET_TYPE_CODE = B.SHEET_TYPE_CODE - ) C - GROUP BY C.SHEET_TYPE_CODE,C.TotalQty - "; - - DataTable dt4 = LeadDbHelperSQLite.Query(sql4).Tables[0].Copy(); - if (dt4 != null && dt4.Rows.Count > 0) - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】按照板材分类和清洗方式统计的数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - } - else - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】按照板材分类和清洗方式统计的数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); - } - - dt4.TableName = "Table4"; - - - string sql5 = $@" - SELECT - SUM (CURRENT_NUMBER) CleanedSheets, - date (INPUT_TIME) DateAndTime, - USER_NAME Operator - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - GROUP BY - date (INPUT_TIME), - OPERATE_USER_ID, - USER_CODE, - USER_NAME - "; - - DataTable dt5 = LeadDbHelperSQLite.Query(sql5).Tables[0].Copy(); - if (dt5 != null && dt5.Rows.Count > 0) - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】操作员每日作业板材数量的数据获取成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - } - else - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】操作员每日作业板材数量的数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); - } - dt5.TableName = "Table5"; - - string userName = dt.Rows[0]["USER_NAME"].ToString(); - DateTime dateMsg = Convert.ToDateTime(dt.Rows[0]["INPUT_TIME"]); - string IRNumber = dt.Rows[0]["IR_CODE"].ToString(); - string MacCode = Global.MacCode; //GlobalHelper.ParameterList.Select(" PARAMETER_CODE = 'CleanMachineName'")[0]["PARAMETER_VALUE"].ToString(); - - string sqlCleanedNum = $@" - SELECT - SUM(CURRENT_NUMBER) CURRENT_NUMBER - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - AND CLEAN_MODE_CODE = 'SortedCleaned' - "; - DataTable dtCleanedNum = LeadDbHelperSQLite.Query(sqlCleanedNum).Tables[0]; - string cleanNum = dtCleanedNum.Rows[0][0].ToString(); - - string sqlPalletNum = $@" - SELECT - DISTINCT WORKING_PALLET_CODE - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - "; - DataTable dtPalletNum = LeadDbHelperSQLite.Query(sqlPalletNum).Tables[0]; - string palletNum = dtPalletNum.Rows.Count.ToString(); - - string sqlScrapNum = $@" - SELECT - SUM(CURRENT_NUMBER) CURRENT_NUMBER - FROM - VW_WORKING_PALLET_MSG - WHERE - IR_CODE = '{workingIrCodeMsg}' - AND CLEAN_MODE_CODE <> 'SortedCleaned' - "; - DataTable dtScrapNum = LeadDbHelperSQLite.Query(sqlScrapNum).Tables[0]; - string scrapNum = dtScrapNum.Rows[0][0].ToString(); - - DataSet dts = new DataSet(); - dts.Tables.Add(dt1); - dts.Tables.Add(dt2); - dts.Tables.Add(dt3); - dts.Tables.Add(dt4); - dts.Tables.Add(dt5); - - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印模板所需要的数据拼装完成!~~~~~~~~~~~~~~", LogTypeEum.Run); - - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】开始加载打印控件类!~~~~~~~~~~~~~~", LogTypeEum.Run); - Report report = new Report(); - string filename = _reportFolder + "CleanMac_IRMsg_PrintMd.frx"; - report.Load(filename); - report.RegisterData(dts); - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类加载完成,数据传入成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - report.SetParameterValue("Parm_CusName", userName); - report.SetParameterValue("Parm_MachineCode", MacCode); - report.SetParameterValue("Parm_IRNumber", IRNumber); - report.SetParameterValue("Parm_RecDate", dateMsg); - report.SetParameterValue("Parm_RecordName", userName); - report.SetParameterValue("Parm_CleanedNum", cleanNum); - report.SetParameterValue("Parm_PalletNumber", palletNum); - report.SetParameterValue("Parm_ScrapNumber", scrapNum); - - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类所需参数设置成功,开始发送打印机数据!~~~~~~~~~~~~~~", LogTypeEum.Run); - report.Prepare(); - report.PrintSettings.ShowDialog = false; - report.Print(); - report.Clear(); - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印控件类发送打印机数据成功!~~~~~~~~~~~~~~", LogTypeEum.Run); - } - else - { - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】打印明细数据获取失败!~~~~~~~~~~~~~~", LogTypeEum.Err); - } - LogHelper.WriteLog($"~~~~~~~~~~~~~~作业IR:【{workingIrCodeMsg}】自动打印结束。~~~~~~~~~~~~~~", LogTypeEum.Run); - } - catch (Exception) - { - - } + new CleanMachine.BLL.CM.IncomingReceipt().Print(workingIrCodeMsg, Global.MacCode, this._reportFolder); } private int remainingQty = 0; @@ -1710,6 +1570,16 @@ namespace CleanMachineHMI.FrmUserControl })); + var shiftCount = PlcOperationHelper.Instance.ReadPlcItem("ShiftCount").ToString(); + this.BeginInvoke(new Action(() => + { + this.ktb_ShiftCount.Text = shiftCount; + + })); + + + + //防止中途关闭系统产生数据丢失,因此每周期都会更新数据 string sql = $@"SELECT SUM(CURRENT_NUMBER) FROM CM_WORKING_PALLET_DTL WHERE CLEAN_MODE_CODE = 'SortedCleaned' AND IR_CODE = '{ktb_IRTest}' AND SHEET_TYPE_CODE = '{kcmb_SheetTypeText}'"; object obj = LeadDbHelperSQLite.GetSingle(sql); @@ -3761,6 +3631,26 @@ namespace CleanMachineHMI.FrmUserControl private void ktb_IR_TextChanged_1(object sender, EventArgs e) { this.kdtp_RecordDate.Value = DateTime.Now; + } + + private void kryptonButton8_Click(object sender, EventArgs e) + { + + var bll = new CleanMachine.BLL.CM.ShiftCountBLL(); + + if (bll.Add(new CleanMachine.Model.CM.ShiftCount() + { + Count = int.Parse(this.ktb_ShiftCount.Text), + DateTime = DateTime.Now + })) + { + PlcOperationHelper.Instance.WritePlcItem("ShiftCount", "0", PlcItemTypeDesc.D); + + } + + + + } } } diff --git a/CleanMachineHMI/FrmUserControl/frmMaintenance.cs b/CleanMachineHMI/FrmUserControl/frmMaintenance.cs index 280c070..54ce4d7 100644 --- a/CleanMachineHMI/FrmUserControl/frmMaintenance.cs +++ b/CleanMachineHMI/FrmUserControl/frmMaintenance.cs @@ -1,4 +1,5 @@ -using CleanMachineHMI.Domain.Enums; +using CleanMachine.Model.BAS; +using CleanMachineHMI.Domain.Enums; using CleanMachineHMI.Utils; using Krypton.Toolkit; using LeadDataBaseUtility; diff --git a/CleanMachineHMI/FrmUserControl/frmManual.cs b/CleanMachineHMI/FrmUserControl/frmManual.cs index ddf4972..a527cf2 100644 --- a/CleanMachineHMI/FrmUserControl/frmManual.cs +++ b/CleanMachineHMI/FrmUserControl/frmManual.cs @@ -1,4 +1,5 @@ -using CleanMachineHMI.Domain.Enums; +using CleanMachine.Model.BAS; +using CleanMachineHMI.Domain.Enums; using CleanMachineHMI.Utils; using Krypton.Toolkit; using NX_LogUtility; diff --git a/CleanMachineHMI/FrmUserControl/frmMechineCheck.cs b/CleanMachineHMI/FrmUserControl/frmMechineCheck.cs index dedfdfa..f048d9e 100644 --- a/CleanMachineHMI/FrmUserControl/frmMechineCheck.cs +++ b/CleanMachineHMI/FrmUserControl/frmMechineCheck.cs @@ -1,4 +1,5 @@ -using CleanMachineHMI.Domain.Enums; +using CleanMachine.Model.BAS; +using CleanMachineHMI.Domain.Enums; using CleanMachineHMI.Utils; using Krypton.Toolkit; using System; diff --git a/CleanMachineHMI/FrmUserControl/frmPlcAlarmLog.cs b/CleanMachineHMI/FrmUserControl/frmPlcAlarmLog.cs index 42a45bd..f9deade 100644 --- a/CleanMachineHMI/FrmUserControl/frmPlcAlarmLog.cs +++ b/CleanMachineHMI/FrmUserControl/frmPlcAlarmLog.cs @@ -1,4 +1,5 @@ using CleanMachine.Model; +using CleanMachine.Model.BAS; using CleanMachine.Model.CM; using CleanMachineHMI.Domain.Enums; using CleanMachineHMI.Utils; diff --git a/CleanMachineHMI/FrmUserControl/frmPlcItemConfig.cs b/CleanMachineHMI/FrmUserControl/frmPlcItemConfig.cs index 51c4d7e..70dfaac 100644 --- a/CleanMachineHMI/FrmUserControl/frmPlcItemConfig.cs +++ b/CleanMachineHMI/FrmUserControl/frmPlcItemConfig.cs @@ -165,7 +165,7 @@ namespace CleanMachineHMI.FrmUserControl { if (kcmb_plcItemDateType.SelectedIndex != 0) { - tmpMdList = tmpMdList.FindAll(x => x.PlcItemDataType == (kcmb_plcItemDateType.SelectedIndex - 1)); + tmpMdList = tmpMdList.FindAll(x => x.PlcItemDataType == (PlcItemTypeDesc) (kcmb_plcItemDateType.SelectedIndex - 1)); } if (tmpMdList != null && tmpMdList.Count > 0) { @@ -224,15 +224,15 @@ namespace CleanMachineHMI.FrmUserControl dr["PLC变量类型"] = "Read and Write"; } - if (item.PlcItemDataType == 0) + if (item.PlcItemDataType == PlcItemTypeDesc.M) { dr["PLC变量数据类型"] = "M Type"; } - else if (item.PlcItemDataType == 1) + else if (item.PlcItemDataType == PlcItemTypeDesc.D) { dr["PLC变量数据类型"] = "D Type"; } - else if (item.PlcItemDataType == 2) + else if (item.PlcItemDataType == PlcItemTypeDesc.X) { dr["PLC变量数据类型"] = "X Type"; } diff --git a/CleanMachineHMI/Utils/GlobalHelper.cs b/CleanMachineHMI/Utils/GlobalHelper.cs index 133d8a9..e9ab112 100644 --- a/CleanMachineHMI/Utils/GlobalHelper.cs +++ b/CleanMachineHMI/Utils/GlobalHelper.cs @@ -182,15 +182,16 @@ namespace CleanMachineHMI public static bool SysThIsRunFlag { get; set; } #region 委托事件 //定义一个委托类型的事件 - public static event EventHandler OnShowX_Y_Status; public static bool eventLock = false; - public static void ShowX_Y_Status(object sender, EventArgs e) - { - if (!eventLock) - { - OnShowX_Y_Status?.Invoke(sender, e); - } - } + //public static event EventHandler OnShowX_Y_Status; + + //public static void ShowX_Y_Status(object sender, EventArgs e) + //{ + // if (!eventLock) + // { + // OnShowX_Y_Status?.Invoke(sender, e); + // } + //} //定义一个委托类型的事件 public static event EventHandler OnShowSensorStatus; public static void ShowSensorStatus(object sender, EventArgs e) @@ -200,7 +201,7 @@ namespace CleanMachineHMI OnShowSensorStatus?.Invoke(sender, e); } } - //定义一个委托类型的事件 + // 定义一个委托类型的事件 public static event EventHandler OnShowMainFrmAlarmMsg; public static bool eventAlarmLock = false; public static void ShowMainFrmAlarmMsg(object sender, EventArgs e) diff --git a/CleanMachineHMI/Utils/PlcOperationHelper.cs b/CleanMachineHMI/Utils/PlcOperationHelper.cs index dc338d5..1ab371e 100644 --- a/CleanMachineHMI/Utils/PlcOperationHelper.cs +++ b/CleanMachineHMI/Utils/PlcOperationHelper.cs @@ -79,8 +79,31 @@ namespace CleanMachineHMI } + public delegate void ShowX_Y_Status(IEnumerable plcItem); + public event ShowX_Y_Status OnShowX_Y_Status; + + private void PostShowX_Y_Status(object data) + { + var _data = data as IEnumerable; + OnShowX_Y_Status?.Invoke(_data); + + } + + + + public void DoShowX_Y_Status(IEnumerable plcItem) + { + + if (_synchronization != null) + { + _synchronization.Post(this.PostShowX_Y_Status, plcItem); + // OnShowX_Y_Status?.Invoke(plcItem); + } + + } + @@ -98,11 +121,7 @@ namespace CleanMachineHMI { get { - - return this._isConn; - - } set { this._isConn = value; } } @@ -144,7 +163,7 @@ namespace CleanMachineHMI { while (Global.SysThIsRunFlag) { - var haschange=false; + var haschange = false; RefreshPlcItem_M(ref haschange); RefreshPlcItem_D(ref haschange); RefreshPlcItem_X(ref haschange); @@ -176,17 +195,17 @@ namespace CleanMachineHMI { switch (plcitem.PlcItemDataType) { - case 0: + case PlcItemTypeDesc.M: PlcItemMd_M_List.Add(plcitem); break; - case 1: + case PlcItemTypeDesc.D: PlcItemMd_D_List.Add(plcitem); break; - case 2: + case PlcItemTypeDesc.X: PlcItemMd_X_List.Add(plcitem); break; - case 3: + case PlcItemTypeDesc.Y: PlcItemMd_Y_List.Add(plcitem); break; } @@ -338,6 +357,7 @@ namespace CleanMachineHMI try { #endif + ushort[] tmpReadAlarmBytArr_D = master.ReadHoldingRegisters(slaveAddress, 4106, 50); ushort[] readBytArr_D = master.ReadHoldingRegisters(slaveAddress, 4505, 50); if (readBytArr_D.Length > 0 && tmpReadAlarmBytArr_D.Length > 0) @@ -396,8 +416,10 @@ namespace CleanMachineHMI if (item.PlcItemValue != value) { haschange = true; + item.PlcItemValue = value; + } - item.PlcItemValue = value; + } @@ -789,6 +811,7 @@ namespace CleanMachineHMI try { #endif + List changeItems = new List(); bool[] readBytArr_X = master.ReadInputs(slaveAddress, 1024, 50); if (readBytArr_X.Length > 0) //if(true) @@ -810,7 +833,9 @@ namespace CleanMachineHMI { haschange = true; item.PlcItemValue = value; - Global.ShowX_Y_Status(item, new EventArgs()); + // this.DoShowX_Y_Status(item); + changeItems.Add(item); + // Global.ShowX_Y_Status(item, new EventArgs()); Global.ShowSensorStatus(item, new EventArgs()); } @@ -826,6 +851,8 @@ namespace CleanMachineHMI } } + + this.DoShowX_Y_Status(changeItems); } } #if RELEASE @@ -843,6 +870,9 @@ namespace CleanMachineHMI try { #endif + + + List changeItems = new List(); bool[] readBytArr_Y = master.ReadCoils(slaveAddress, 1280, 50); if (readBytArr_Y.Length > 0) //if(true) @@ -863,22 +893,19 @@ namespace CleanMachineHMI { if (item.PlcItemValue != value) { - haschange=true; + haschange = true; item.PlcItemValue = value; - Global.ShowX_Y_Status(item, new EventArgs()); - + changeItems.Add(item); + // this.DoShowX_Y_Status(item); + // Global.ShowX_Y_Status(item, new EventArgs()); } - - } - //Random r = new Random(); //item.PlcItemValue = r.Next(0, 2) == 0 ? "False" : "True"; - - - } } + + this.DoShowX_Y_Status(changeItems); } } #if RELEASE @@ -900,7 +927,7 @@ namespace CleanMachineHMI { return null; } - if (item.PlcItemDataType == 1) + if (item.PlcItemDataType == PlcItemTypeDesc.D) { if (string.IsNullOrEmpty(item.PlcItemValue)) @@ -1157,23 +1184,5 @@ namespace CleanMachineHMI - public enum PlcItemTypeDesc - { - /// - /// M 类型布尔变量 - /// - M, - /// - /// D 类型整数变量 - /// - D, - /// - /// X 类型布尔变量 - /// - X, - /// - /// Y 类型布尔变量 - /// - Y - } + } diff --git a/CleanMachineHMI/frmChild/frmSwitchRunDirection.cs b/CleanMachineHMI/frmChild/frmSwitchRunDirection.cs index f2d246d..6e71a97 100644 --- a/CleanMachineHMI/frmChild/frmSwitchRunDirection.cs +++ b/CleanMachineHMI/frmChild/frmSwitchRunDirection.cs @@ -1,4 +1,5 @@ -using CleanMachineHMI.Utils; +using CleanMachine.Model.BAS; +using CleanMachineHMI.Utils; using Krypton.Toolkit; using System; using System.Collections.Generic; diff --git a/CleanMachineHMI/frmIoMonitorNew.cs b/CleanMachineHMI/frmIoMonitorNew.cs index e0660f5..3e73cca 100644 --- a/CleanMachineHMI/frmIoMonitorNew.cs +++ b/CleanMachineHMI/frmIoMonitorNew.cs @@ -42,7 +42,7 @@ namespace CleanMachineHMI await Task.Delay(100); Invoke(new Action(() => { - Global.OnShowX_Y_Status -= Show_X_Y_Status; + PlcOperationHelper.Instance.OnShowX_Y_Status -= Show_X_Y_Status; Global.OnShowSensorStatus -= ShowSensorStatus; Global.IoMonitor_2.SuspendLayout(); Global.IoMonitor_2.Hide(); @@ -58,7 +58,7 @@ namespace CleanMachineHMI private void frmIoMonitorNew_2_Load(object sender, EventArgs e) { initControl(); - Global.OnShowX_Y_Status += Show_X_Y_Status; + PlcOperationHelper.Instance.OnShowX_Y_Status += Show_X_Y_Status; Global.OnShowSensorStatus += ShowSensorStatus; } private void ShowSensorStatus(object sender, EventArgs e) @@ -68,7 +68,7 @@ namespace CleanMachineHMI PlcItem item = sender as PlcItem; Invoke(new Action(() => { - if (item.PlcItemDataType == 2) + if (item.PlcItemDataType == PlcItemTypeDesc.X) { Control[] crnLst = this.Controls.Find("picb_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true); if (crnLst.Length > 0) @@ -111,55 +111,58 @@ namespace CleanMachineHMI })); } } - private void Show_X_Y_Status(object sender, EventArgs e) + private void Show_X_Y_Status( IEnumerable< PlcItem> items ) { lock (lockObj) { - PlcItem item = sender as PlcItem; - Invoke(new Action(() => + foreach (var item in items) { - if (item.PlcItemDataType == 2) + + Invoke(new Action(() => { - - Control[] crnLst = this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true); - if (crnLst.Length > 0) - { - CircleButton ctn = crnLst[0] as CircleButton; - if (string.IsNullOrEmpty(item.PlcItemValue)) + if (item.PlcItemDataType == PlcItemTypeDesc.X) + { + + Control[] crnLst = this.Controls.Find("cbt_X" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true); + if (crnLst.Length > 0) { - ctn.BackColor = Color.FromArgb(191, 219, 255); + CircleButton ctn = crnLst[0] as CircleButton; + if (string.IsNullOrEmpty(item.PlcItemValue)) + { + ctn.BackColor = Color.FromArgb(191, 219, 255); + } + else if (bool.Parse(item.PlcItemValue.ToString())) + { + ctn.BackColor = Color.Lime; + } + else + { + ctn.BackColor = Color.Red; + } } - else if (bool.Parse(item.PlcItemValue.ToString())) + } + else + { + Control[] crnLst = this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true); + if (crnLst.Length > 0) { - ctn.BackColor = Color.Lime; + CircleButton ctn = crnLst[0] as CircleButton; + if (string.IsNullOrEmpty(item.PlcItemValue)) + { + ctn.BackColor = Color.FromArgb(191, 219, 255); + } + else if (bool.Parse(item.PlcItemValue.ToString())) + { + ctn.BackColor = Color.Lime; + } + else + { + ctn.BackColor = Color.Red; + } } - else - { - ctn.BackColor = Color.Red; - } - } - } - else - { - Control[] crnLst = this.Controls.Find("cbt_Y" + Convert.ToString(Convert.ToInt32(item.PlcItemPriAddress), 8).PadLeft(2, '0'), true); - if (crnLst.Length > 0) - { - CircleButton ctn = crnLst[0] as CircleButton; - if (string.IsNullOrEmpty(item.PlcItemValue)) - { - ctn.BackColor = Color.FromArgb(191, 219, 255); - } - else if (bool.Parse(item.PlcItemValue.ToString())) - { - ctn.BackColor = Color.Lime; - } - else - { - ctn.BackColor = Color.Red; - } - } - } - })); + } + })); + } } } private void initControl()