public void AfterSelect(object sender, TreeViewEventArgs e)
        {
            string Function_Name = "AfterSelect";

            try
            {
                TreeNode selectedNode = m_View.getSelectedNode();
                if (selectedNode.Nodes.Count < 1)
                {
                    Dictionary <ulong, EtyEntity> childNodes  = m_Model.GetDataNodeChildrenByPkey((ulong)(selectedNode.Tag));
                    Dictionary <ulong, EtyEntity> childPoints = m_Model.GetDataPointByDNPkey((ulong)(selectedNode.Tag));

                    m_View.LoadDataNodeChildren(ref selectedNode, childNodes);
                    m_View.LoadDataPointToGridView(childPoints);
                }
                else
                {
                    Dictionary <ulong, EtyEntity> childPoints = m_Model.GetDataPointByDNPkey((ulong)(selectedNode.Tag));
                    m_View.LoadDataPointToGridView(childPoints);
                }
            }
            catch (Exception localException)
            {
                LogHelper.Error(CLASS_NAME, Function_Name, localException.ToString());
            }
        }
Exemple #2
0
        public static System.Windows.Forms.TreeNode getSelectedNodeMSS(
            TrendViewer.View.OPCDataSelector target)
        {
            object result;

            if (TestSpecificStubsUtil.RunTestSpecificStub(System.Reflection.MethodBase.GetCurrentMethod(), new object[] { target }, out result))
            {
                return((System.Windows.Forms.TreeNode)result);
            }
            else
            {
                return(target.getSelectedNode());
            }
        }