is used when a node of a collection has its own children which are also wrapped in a collection
. In order to relate each child to a DataTemplate
, the ItemTemplate
properties of the HierarchicalDataTemplate
must be used.
In your case a DataTemplate
can be used to display the children of EmployeeA
. A HierarchicalDataTemplate
is needed to display all employees in one department and one more HierarchicalDataTemplate
to display all departments in the collection.
For better understanding and your convenience I have attached a SampleProject
which you may go through.
For further information you may follow the links bellow:
- How to bind to hierarchical data
- Binding data using ItemTemplateSelector
Please let me know if my answer satisfy your needs.
All the best,
the Telerik team