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

Data binding in IsTriStateMode

2 Answers 39 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Kristjan Einarsson
Top achievements
Rank 1
Kristjan Einarsson asked on 07 Apr 2011, 05:22 PM
Hi
When I data bind TreeView and use IsChecked, witch works fine but it looks something like this:
[ ]Beverages
 |__ [ ] Alcoholic
 |       |__ [X] Beer
 |......

But I would like it to look like this (with the Indeterminate state)
[-]Beverages
 |__ [-] Alcoholic
 |       |__ [X] Beer
 |......

Is there any way to get this functionality when data binding ? or do I need to do this manually ?

Best regards
Kristján

2 Answers, 1 is accepted

Sort by
0
Kristjan Einarsson
Top achievements
Rank 1
answered on 08 Apr 2011, 12:27 PM
spoke to soon, my converter was just returning ToogleState.On / Off but not Indeterminate.
0
Petar Mladenov
Telerik team
answered on 13 Apr 2011, 08:52 AM
Hello Kristjan Einarsson,

Actually, you don't need a converter if you use the CheckState property of your RadTreeViewitem which is of type System.Windows.Automation.ToggleState. Please examine the approach in the attached solution and let us know if it helps you.

Regards,
Petar Mladenov
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
Kristjan Einarsson
Top achievements
Rank 1
Answers by
Kristjan Einarsson
Top achievements
Rank 1
Petar Mladenov
Telerik team
Share this question
or