Quantcast
Viewing all articles
Browse latest Browse all 18858

WPF Custom Control Display only part of hierarchical structure

Hi Guys, 
at the moment I am working on a custom control that allows the user to navigate through levels of hierarchical data. 
Data example: 
Node 1
        Node 1.1 
        Node1.2
                Node1.2.1
                Node1.2.2
Node 2 
Node 3 
        Node3.1
        Node3.2
Node 4
The control always displays the current level of data, for example all children of Node3 (3.1 and 3.2). The User should be able to navigate through the hierarchical data by clicking on an item or pressing a back-button.  The problem with that is that I don´t know the class type of the view model objects so I don´t know which property contains the child nodes of each node. As I need to access their child nodes for navigation I can´t use binding in a data template because the related items aren’t yet created (as they are displayed in a list, not a tree!). 

Any ideas on how to solve this problem elegantly? 



Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>