c# - Add Sub child Nodes in TreeView -
How to add node hair sub-child nodes?
{tree node tree node = new treeoid ("windows"); TreeView1.Nodes.Add (treeNode); TriNode = new triode ("Linux"); TreeView1.Nodes.Add (treeNode); TreeNode node2 = new triode ("C #"); TreeNode node3 = New Treeode ("VB.Net"); Treeoid [] array = new tree node [] {node 2, node 3}; Node2 = new triode ("child nodes", array); TreeView1.Nodes.Add (node2); } << Code>
try it
{TreeNode treeNode = New triode ("windows"); TreeNode node2 = new triode ("C #"); TreeNode node3 = New Treeode ("VB.Net"); Node2.Nodes.Add ("whatever"); TreeNode.Nodes.Add (node2); TreeNode.Nodes.Add (node3); TreeView1.Nodes.Add (treeNode); TriNode = new triode ("Linux"); TreeView1.Nodes.Add (treeNode); }
Comments
Post a Comment