コード例 #1
0
        /// <summary>
        /// when the user click menu "Load data point configuration"
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public void LoadDataPoint(object sender, EventArgs e)
        {
            IView view = ViewManager.GetInstance().GetView(TrendViewConst.LoadConfigDataPoint, m_View.ViewID);

            DataPointGroupController ctl = (DataPointGroupController)(view.getController());

            ctl.SetFormType(FormType.Load);

            ctl.InitDPGrp();
            ((DataPointGroup)view).SetFormType(FormType.Load);
            ((DataPointGroup)view).FillConfigNameBox(ctl.GetDataPointGrpNames());
            ((DataPointGroup)view).SetCurrentGrpName(m_grpName);
            view.ShowView(true);
        }
コード例 #2
0
        /// <summary>
        /// when user clicked "save datapoint coinfiguration" menu
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        public void SaveDataPoint(object sender, EventArgs e)
        {
            string Function_Name = "SaveDataPoint";

            try
            {
                IView view = ViewManager.GetInstance().GetView(TrendViewConst.SaveConfigDataPoint, m_View.ViewID);

                DataPointGroupController ctl = (DataPointGroupController)(view.getController());

                ctl.SetFormType(FormType.Save);

                ctl.InitDPGrp();
                ((DataPointGroup)view).SetFormType(FormType.Save);
                ((DataPointGroup)view).FillConfigNameBox(ctl.GetDataPointGrpNames());
                ((DataPointGroup)view).SetCurrentGrpName(m_grpName);
                view.ShowView(true);
            }
            catch (Exception localException)
            {
                LogHelper.Error(CLASS_NAME, Function_Name, localException.ToString());
            }
        }