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

add bullet to treeview nodes

1 Answer 56 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Michael Finch
Top achievements
Rank 1
Michael Finch asked on 27 Aug 2008, 02:12 PM

Hi

I'm using a customised version of the TreeView Default skin and would like to add an image (bullet) to only the deepest nodes (nodes which cannot be expanded or collapsed) and was wondering how I could do this? Thanks.

Kind Regards

1 Answer, 1 is accepted

Sort by
0
Yana
Telerik team
answered on 28 Aug 2008, 01:07 PM
Hi Michael,

I suggest you find the deepest nodes of RadTreeView on server-side and set their ImageUrl property like this:

foreach (RadTreeNode node in RadTreeView1.GetAllNodes())  
{  
   if (node.Nodes.Count == 0)  
    {  
        node.ImageUrl = "bullet.gif";  
    }  

Hope this helps.

Regards,
Yana
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
TreeView
Asked by
Michael Finch
Top achievements
Rank 1
Answers by
Yana
Telerik team
Share this question
or