private void FrmDiscreteAlarm_Load(object sender, System.EventArgs e) { objAlarmManager = AlarmManagers.GetAlarmManager(); string xmlFile = objAlarmManager.ReadKey(AlarmManagers.XML_NAME_DEFAULT); if (string.IsNullOrEmpty(xmlFile) || string.IsNullOrWhiteSpace(xmlFile)) { return; } InitializeData(xmlFile); }
public HMIAlarm() { InitializeComponent(); dbCurrent = new List <ClassAlarm>(); objAlarmManager = AlarmManagers.GetAlarmManager(); string xmlFile = objAlarmManager.ReadKey(AlarmManagers.XML_NAME_DEFAULT); if (string.IsNullOrEmpty(xmlFile) || string.IsNullOrWhiteSpace(xmlFile)) { return; } dbCurrent = InitializeData(xmlFile); }