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

How to use item templates

2 Answers 87 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Gus Oakes
Top achievements
Rank 1
Gus Oakes asked on 20 Aug 2009, 05:11 PM

I am trying to create a tree where each item in the tree would have a label (header) and two clickable items (such as buttons) to do particular actions on that item. Nodes need to be populated on demand from the server. I have this working in the ASP.NET versions of the controls, but I am trying to get it done in Silverlight for comparison. To do this, I need to:

  - add extra controls into each tree item
  - make the tree populated dynamically
  - be able to identify the containing tree item when one of the buttons is clicked


Right now, I'm stuck on the first one... I understand this is done with templates. What is the bare minimum needed to get templates working in a tree? I'm hoping for something as simple as the ASP.NET one, with a default template, and I would like it to apply the template automatically to new items loaded from the server.

If you could also point me in the right direction for the third item, I'd appreciate it... :)

2 Answers, 1 is accepted

Sort by
0
Accepted
Tihomir Petkov
Telerik team
answered on 21 Aug 2009, 10:18 AM
Hi Gus,

I prepared a sample project for you. Please take a look at it and let me know if it helps.

Sincerely yours,
Tihomir Petkov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Gus Oakes
Top achievements
Rank 1
answered on 21 Aug 2009, 01:24 PM
Awesome, that's just what I need. Thanks.
Tags
TreeView
Asked by
Gus Oakes
Top achievements
Rank 1
Answers by
Tihomir Petkov
Telerik team
Gus Oakes
Top achievements
Rank 1
Share this question
or