Connecting Tech Pros Worldwide Forums | Help | Site Map

Dynamic Tree View Control

Newbie
 
Join Date: Jan 2008
Location: Pune
Posts: 1
#1: Jan 14 '08
Hi

Can we add dynamiclly nodes and information in tree view control.

QVeen72's Avatar
Moderator
 
Join Date: Oct 2006
Location: Bangalore
Posts: 1,385
#2: Jan 14 '08

re: Dynamic Tree View Control


Hi,

Yes, you can..
This code will add to the root:
Expand|Select|Wrap|Line Numbers
  1. TreeView1.Nodes.Add , tvwChild, , "New Root Node"
  2.  
This will add as a Child Node to selected node
Expand|Select|Wrap|Line Numbers
  1. TreeView1.Nodes.Add TreeView1.SelectedItem.Key,tvwChild, , "New Child"
  2.  
Regards
Veena
debasisdas's Avatar
Moderator
 
Join Date: Dec 2006
Location: Bangalore ,India
Posts: 7,511
#3: Jan 14 '08

re: Dynamic Tree View Control


Please find a related discussion here.
Reply