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

Assigning Node Images

1 Answer 61 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Kyle
Top achievements
Rank 1
Kyle asked on 16 Dec 2010, 10:57 PM
Hi,

Is there any way to globally assign a node image dependent on if it's a parent or not?

I have code the sets the image based on the node.count for each node, but after re-binding the datasource, the RadControls blow-up.  It's almost as if the prior datasource is still being enumerated.

Anyway, if there's a better way for me to do this, rather than walking through the entire tree, I'd appreciate the knowledge.

Thanks,

1 Answer, 1 is accepted

Sort by
0
Cori
Top achievements
Rank 2
answered on 17 Dec 2010, 02:26 PM
Hello Kyle,

I don't really think there is any other way to determine the parent/child nodes without looping through the entire tree. I would handle the RadTreeView's PreRender event, to loop through the nodes and set the image urls. No need to rebind.
Tags
TreeView
Asked by
Kyle
Top achievements
Rank 1
Answers by
Cori
Top achievements
Rank 2
Share this question
or