Hi to all,
I am actually working in a project that includes a RadTreeView and i have a question about it... I bind the ItemsSource property of the TreeView to a Hierarchical collection previously elaborated, the collection objects have the properties string Nombre, bool IsSelected, obscollection<myObject> Children among others... but those are importants. Now, i use the next Hierarchical Template:
<telerik:HierarchicalDataTemplate |
x:Key="HTemplate" |
telerik:ContainerBinding.ContainerBindings="{StaticResource BindingsCollection}" |
ItemsSource="{Binding Children}"> |
<StackPanel Orientation="Horizontal"> |
<CheckBox x:Name="checky" Tag="{Binding Codigo}" Content="{Binding Nombre}" IsChecked="{Binding IsSelected, Mode=TwoWay}"/> |
</StackPanel> |
</telerik:HierarchicalDataTemplate> |
and the next BindingCollection:
<telerik:ContainerBindingCollection x:Name="BindingsCollection"> |
<telerik:ContainerBinding PropertyName="IsSelected" Binding="{Binding IsSelected, Mode=TwoWay}" /> |
</telerik:ContainerBindingCollection> |
Now, i was wondering, how could i expand the path to certain object that have the property IsSelected = true at the time the treeview is loaded?
Something like this....
-Node1
-Node4
-Node6
-Node7
-Object.IsSelected = true;
-Node5
-Node2
-Node3
Also, can i select multiple objects at the same time? And how hard would it be to perform a Search in this hierarchical collection, highlighting and expanding the parent nodes the objects that corresponds to the search parameterS?
I would really appreciate some help with this... hope you have some ideas...
Greetins!