Beispiel #1
0
        /// <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);
            }
        }
Beispiel #2
0
        /// <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);
                }
            }
        }
Beispiel #3
0
 /// <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);
         }
     }
 }
Beispiel #4
0
 /// <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);
     }
 }