This is a migrated thread and some comments may be shown as answers.

Self-referencing Hierarchy with LinqDataSource

1 Answer 86 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Thanh Dang
Top achievements
Rank 2
Thanh Dang asked on 12 Aug 2011, 07:11 PM
Hello

How can I make a grid with self-reference hierarchy using LinqDataSource?

I followed this demo: http://demos.telerik.com/aspnet-ajax/grid/examples/hierarchy/selfreferencing/defaultcs.aspx
but the grid could load root level items only.

Is the FilterExpression the reason? This is my FilterExpression, with datakeys CategoryID and ParentID : RadGrid1.MasterTableView.FilterExpression = @"ParentID == null";

Hope the answer will come soon...
Regards
Thanh Dang 





1 Answer, 1 is accepted

Sort by
0
Mira
Telerik team
answered on 17 Aug 2011, 03:07 PM
Hello Thanh,

The self-referencing hierarchy feature of the grid should work with LinqDataSource as well.

However, I recommend that you use the RadTreeList control for representation of self-hierarchical data. You can see how the treelist is bound to LinqDataSource here.

I hope this helps.

Kind regards,
Mira
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Tags
Grid
Asked by
Thanh Dang
Top achievements
Rank 2
Answers by
Mira
Telerik team
Share this question
or