启动 加载语言配置文件
This commit is contained in:
@@ -54,7 +54,7 @@ namespace CleanMachineHMI.frmChild
|
||||
try
|
||||
{
|
||||
InitControlEvent();
|
||||
this.SetFormControlText(GlobalHelper.LanguageCode);
|
||||
this.SetFormControlText();
|
||||
if (GlobalHelper.LanguageCode == "English")
|
||||
{
|
||||
kcmb_WarningType.Items.Clear();
|
||||
@@ -79,7 +79,7 @@ namespace CleanMachineHMI.frmChild
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("编辑基础报警数据界面加载异常", "LoadEditFrmExp") + $":【{ex.Message}】!");
|
||||
KryptonMessageBox.Show(this.GetInfoText("编辑基础报警数据界面加载异常", "LoadEditFrmExp") + $":【{ex.Message}】!");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -90,19 +90,19 @@ namespace CleanMachineHMI.frmChild
|
||||
if (string.IsNullOrEmpty(txtWarningCode.Text))
|
||||
{
|
||||
//KryptonMessageBox.Show("请输入报警条码!");
|
||||
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请输入报警条码!", "EnterWarningCodeInfo"));
|
||||
KryptonMessageBox.Show(this.GetInfoText("请输入报警条码!", "EnterWarningCodeInfo"));
|
||||
return;
|
||||
}
|
||||
if (string.IsNullOrEmpty(txtWarningName.Text))
|
||||
{
|
||||
//KryptonMessageBox.Show("请输入报警名称!");
|
||||
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请输入报警名称!", "EnterWarningNameInfo"));
|
||||
KryptonMessageBox.Show(this.GetInfoText("请输入报警名称!", "EnterWarningNameInfo"));
|
||||
return;
|
||||
}
|
||||
if (kcmb_WarningType.SelectedIndex == 0)
|
||||
{
|
||||
//KryptonMessageBox.Show("请选择报警类型!");
|
||||
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("请选择报警类型!", "SelectWarningTypeInfo"));
|
||||
KryptonMessageBox.Show(this.GetInfoText("请选择报警类型!", "SelectWarningTypeInfo"));
|
||||
return;
|
||||
}
|
||||
string sqlIsExistCode = $@"SELECT 1 FROM BAS_WARNING WHERE WARNING_TYPE = '{kcmb_WarningType.SelectedIndex}' AND PLC_ITEM_CODE = '{ktb_PlcCode.Text}' AND WARNING_CODE = '{txtWarningCode.Text}'";
|
||||
@@ -118,19 +118,19 @@ namespace CleanMachineHMI.frmChild
|
||||
if (row > 0)
|
||||
{
|
||||
//KryptonMessageBox.Show("修改基础报警数据成功!");
|
||||
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("修改基础报警数据成功!", "EditSuccessInfo"));
|
||||
KryptonMessageBox.Show(this.GetInfoText("修改基础报警数据成功!", "EditSuccessInfo"));
|
||||
//frmWarning.RefreshFrmHost();
|
||||
this.Close();
|
||||
}
|
||||
else
|
||||
{
|
||||
//KryptonMessageBox.Show("修改基础报警数据失败!");
|
||||
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("修改基础报警数据失败!", "EditFailInfo"));
|
||||
KryptonMessageBox.Show(this.GetInfoText("修改基础报警数据失败!", "EditFailInfo"));
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
KryptonMessageBox.Show(_InfoLanguageTextList.GetInfoText("编辑基础报警数据发生异常", "EditWarningDataExp") + $":【{ex.Message}】!");
|
||||
KryptonMessageBox.Show(this.GetInfoText("编辑基础报警数据发生异常", "EditWarningDataExp") + $":【{ex.Message}】!");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user