Esempio n. 1
0
 /// <summary>
 /// 报警配置信息显示
 /// </summary>
 /// <param name="alarmConfig"></param>
 private void setDataToControl(DH_ALARMIN_CFG alarmConfig)
 { 
     try
     {
         chkAlarmEn.Checked = (alarmConfig.byAlarmEn == 1 ? true : false);
         cmbAlarmType.SelectedIndex = alarmConfig.byAlarmType;
         setActionMask(alarmConfig.struHandle);
         cmbAWeeks.SelectedIndex = -1;
         cmbAWeeks.SelectedIndex = 0;
     }
     catch
     {
         MessageBox.Show("赋值错误!", pMsgTitle);
     }
 }
Esempio n. 2
0
 /// <summary>
 /// 保存报警输入信息
 /// </summary>
 /// <param name="AlarmConfig"></param>
 private void AlarmSaveData(ref DH_ALARMIN_CFG AlarmConfig)
 {
     cmbAWeeks_DropDown(null, null);
     AlarmConfig.byAlarmEn = (byte)(chkAlarmEn.Checked==true?1:0);
     AlarmConfig.byAlarmType =(byte) cmbAlarmType.SelectedIndex;
     AlarmSaveData(ref AlarmConfig.struHandle);
     
 }