예제 #1
0
파일: frmMain.cs 프로젝트: leadscloud/lx
        /// <summary>
        ///
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void mnuStationAdd_Click(object sender, EventArgs e)
        {
            StationCollection ss = YeHeCommuniServerApp.Default.CommuniSoft.HardwareManager.Stations;
            frmStationItem    f  = new frmStationItem(ss);
            DialogResult      dr = f.ShowDialog();

            if (dr == DialogResult.OK)
            {
                AddStationToTreeView(this.tvStation, f.Station);
            }
        }
예제 #2
0
파일: frmMain.cs 프로젝트: leadscloud/lx
        /// <summary>
        ///
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void mnuStationEdit_Click(object sender, EventArgs e)
        {
            TreeNode selectedTN = this.tvStation.SelectedNode;

            if (selectedTN != null)
            {
                Station st = selectedTN.Tag as Station;
                if (st != null)
                {
                    StationCollection ss = YeHeCommuniServerApp.Default.CommuniSoft.HardwareManager.Stations;
                    frmStationItem    f  = new frmStationItem(ss, st);
                    DialogResult      dr = f.ShowDialog(this);
                    if (dr == DialogResult.OK)
                    {
                        selectedTN.Text = st.Name;
                    }
                }
                else
                {
                    NUnit.UiKit.UserMessage.DisplayFailure(strings.PleaseSelectStation);
                }
            }
        }
예제 #3
0
파일: frmMain.cs 프로젝트: hkiaipc/lx
 /// <summary>
 /// 
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void mnuStationEdit_Click(object sender, EventArgs e)
 {
     TreeNode selectedTN = this.tvStation.SelectedNode;
     if (selectedTN != null)
     {
         Station st = selectedTN.Tag as Station;
         if (st != null)
         {
             StationCollection ss = YeHeCommuniServerApp.Default.CommuniSoft.HardwareManager.Stations;
             frmStationItem f = new frmStationItem(ss, st);
             DialogResult dr = f.ShowDialog(this);
             if (dr == DialogResult.OK)
             {
                 selectedTN.Text = st.Name;
             }
         }
         else
         {
             NUnit.UiKit.UserMessage.DisplayFailure(strings.PleaseSelectStation);
         }
     }
 }
예제 #4
0
파일: frmMain.cs 프로젝트: hkiaipc/lx
 /// <summary>
 /// 
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void mnuStationAdd_Click(object sender, EventArgs e)
 {
     StationCollection ss = YeHeCommuniServerApp.Default.CommuniSoft.HardwareManager.Stations;
     frmStationItem f = new frmStationItem(ss);
     DialogResult dr = f.ShowDialog();
     if (dr == DialogResult.OK)
     {
         AddStationToTreeView(this.tvStation, f.Station);
     }
 }