We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

How to access child TreeViewItemAdv from a TreeViewItemAdv

Thread ID:

Created:

Updated:

Platform:

Replies:

89977 Sep 12,2009 01:11 AM Sep 15,2009 10:56 AM WPF 1
loading
Tags: Tools
Jackdoh
Asked On September 12, 2009 01:11 AM

I'm trying to create a selection tree. Whenever a button in a parent node is clicked, the children nodes should all be selected.
My problem is i can't find the containers of the children nodes (TreeViewItemAdv collection) from a parent TreeViewItemAdv

I can manually get a container by calling
ParentNode.ItemContainerGenerator.GetContainerFromItem(childData)

But there's another problem, if the ParentNode is collapsed, the child containers haven't been instantiated. Setting ParentNode.IsExpanded = true does not synchronously generate the item containers as I expected.

How do I solve this problem?
Thank you

Prabhu P [Syncfusion]
Replied On September 15, 2009 10:56 AM

Hi Jackdoh,

Thank you for your interest in Syncfusion products.

We have a method named as AddNodeToSelectedItems() for selecting one or more nodes from the Treeview children collection. We have created a simple sample with all your requirement. Please find the sample from the link given below.

http://files.syncfusion.com/support/Tools.WPF/7.3.0.20/F89977/main.htm

Hope this sample will meet requirement. Please let us know if you have any other further queries.

Thanks,
Prabu

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;