23 February 2009

Binding Hierarchical DataSets to TreeView Controls

OOB the ASP.NET TreeView control doesn’t support binding to Hierarchical DataSets. Ralph Varjabedian created a HierarchicalDataSet class to help with this.  Read more about it here.

 

Here’s a snippet…it’s simple to implement:

TreeView1.DataSource = new HierarchicalDataSet(dataSet, "ID", "ParentID");
Filed under: , ,
 

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

# Anith » Binding Hierarchical DataSets to TreeView Controls said:

PingBack from http://www.anith.com/?p=12996

24 February 09 at 4:08 AM

Leave a Comment

Comment Policy: No HTML allowed. URIs and line breaks are converted automatically. Your e–mail address will not show up on any public page.

(required) 
(optional)
(required) 

  
Enter Code Here: Required
Page view tracker