|
-
Mar 29th, 2004, 05:22 AM
#1
Thread Starter
Junior Member
Creating a Child node in a treeview
The folowing code loops round looking for NodeKey to match the NextParent. Nodekey is a Key which I have setup for the Nodes Class
When it matches the key I wish to find the index of that key and then set the selected node to that index and create a new child underneath.
Unfortuently this code does not seem to work. Does anybody have any ideas.
'Loop Round tree View
If (cNode.NodeKey = nextParent) Then
sString = nextElement & " " & nextDesc
iRecord = cNode.Index
TreeView1.SelectedNode = TreeView1.Nodes(iRecord)
Nextmode = TreeView1.SelectedNode
NextMode.Nodes.Add(New HalcrowTreeNode(sString, nextElement))
End If
Thanks in Advance
Daniel
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|