none
Getting the string in a TreeView node RRS feed

  • Question

  • I am trying to grab the sting that labels the node in a TreeViewItem.   I think that the issue is comes from using a HierarchicalDataTemplate to bind the data to the TreeView object.  By using this template the tree structure looks like this...

     

    Control view:

    -tree view

    -tree view item

    -button

     

    Raw view:

    -tree view

    -tree view item

    -button

    -text

     

    The text item that is created in the raw view holds the text string that I am trying to access, but i cannot retrieve this element, even using the RawViewWalker.  An there is no way that I can find to bind the string to a property in the button since the HierachicalDataTemplate is being used to create the TreeView object. 

     

    Has anyone come up against an issue like this?  Any work arounds?  Thanks

    Tuesday, September 30, 2008 6:22 PM