This commit is contained in:
gongxh
2022-03-18 10:12:40 +08:00
parent 5b47fd6d1a
commit 0a4fe0907b
3 changed files with 4 additions and 2 deletions

View File

@@ -147,7 +147,7 @@ namespace CleanMachineHMI
{
this.SetFormControlText(GlobalHelper.LanguageCode);
SwitchFrmMenu = new dlgSwitchFrmMenu(AddFrmMenuPage);
bool isInitStatus = PlcOperationHelper.Instance.PlcInit();
string sql1 = $@" SELECT * FROM BAS_PLC_ITEM ";
DataTable dt1 = LeadDbHelperSQLite.Query(sql1).Tables[0];
if (dt1 != null && dt1.Rows.Count > 0)
@@ -183,6 +183,7 @@ namespace CleanMachineHMI
GlobalHelper.PlcItemMdList.AddRange(GlobalHelper.PlcItemMd_Y_List);
}
InitWarningMsg();
bool isInitStatus = PlcOperationHelper.Instance.PlcInit();
if (isInitStatus)
{
label3Professional.Text = _InfoLanguageTextList.GetInfoText_1("串口打开成功,PLC连接成功!", "label3Professional", "Info_Success");