Exemple #1
0
 public void PopulateTree(MyTreeNode MyTreeRoot, TreeView treeView)
 {
     MyTreeRoot.Text = MyTreeRoot.nNode.sNode;
     treeView.Nodes.Clear();
     treeView.Nodes.Add(MyTreeRoot);
     MyTreeRoot.getTreeNodes();
 }
Exemple #2
0
 public void getTreeNodes()
 {
     if (this.nNode.GetClass() == "Device")
     {
         Device d = (Device)this.nNode;
         foreach (Signal s in d.Signals)
         {
             MyTreeNode a = new MyTreeNode(s);
             a.Text = a.nNode.sNode;
             this.Nodes.Add(a);
         }
     }
     foreach (Node n in this.nNode.Nodes)
     {
         MyTreeNode a = new MyTreeNode(n);
         a.getTreeNodes();
         a.Text = a.nNode.sNode;
         this.Nodes.Add(a);
     }
 }