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

Object-relational / self-referencing

1 Answer 103 Views
Treeview
This is a migrated thread and some comments may be shown as answers.
Graeme Humphrey
Top achievements
Rank 1
Graeme Humphrey asked on 15 Apr 2011, 10:17 AM
Hi,

I'm having a bit of a problem binding the treeview to a list of folders which can contain assets at any level. Essentially what I want is the following:

Folder 1
-> Folder 2
---> Asset 2-1
-> Folder 3
-> Asset 1
---> Asset 1-1

So, a Folder can have Folders and Assets as children. To make it more confusing an Asset can have other Assets as children.

This application, for the moment at least, will not be stored in a database so I would like to bind through the related entities rather than having to use parent Id's etc. From looking through the Telerik samples, it seems that self-referencing and object-relational binding are carried out by different binding providers - is this correct?

Is it possible to carry out the above solely using binding? If not, I may have to end up binding to an object that has parent/child Id's for the self-referencing and also which encapsulates the actual object (Asset/Folder) that I really want to bind to.

I may have just answered my own question there, but I wouldn't mind hearing anyone else's thoughts on this if you have attempted the same thing.

1 Answer, 1 is accepted

Sort by
0
Julian Benkov
Telerik team
answered on 20 Apr 2011, 11:28 AM
Hello Graeme,

For this scenario the only possible solution is to use the Load-On-Demand feature of RadTreeView control. More information you can find in our online documentation.

I hope this information is useful. Let me know if you need further assistance.

All the best,
Julian Benkov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Treeview
Asked by
Graeme Humphrey
Top achievements
Rank 1
Answers by
Julian Benkov
Telerik team
Share this question
or