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. Image for the cookie policy date

TreeViewAdv IsVirtualizing beahavior and TreeViewItemsAdv

Good day,

I am using a TreeViewAdv in a project and I need to set the selected value through C#.  I can set the selection and find the TreeViewItemAdv that contains the object I am looking for through the use of 
TreeViewItemAdv.ItemContainerGenerator.ContainerFromItem(o).  Everything works fine if I accessed the node previously.

The problem I am encountering is that the TreeViewItemAdv does not seem to be created unless you accessed the node, event if the TreeViewAdv.IsVirtualizing  is false.  I also tried setting the TreeViewItemAdv.IsLoadOnDemand to false and in both cases, it does not solve the problem.  I can move through the items fine, but when I try to get the container through the ContainerFromItem function, it returns null, as if the TreeViewItem had not been created.

Is this a bug, or is there another way to get at the TreeViewItemAdv?

Thank you for your time

Mathieu



1 Reply

KR Karthick Ravichandran Syncfusion Team July 18, 2013 10:32 AM UTC

Hi Mathieu,

 

Thanks for using Syncfusion products.

 

We have created a sample to select the treeviewitemadv which retrieved from container generator, please check with the sample in the below location. If you still face any problem, please revert us by modifying the sample based on your application along with replication procedure. This would be helpful for us to serve you.

 

Please let us know if you have any queries.

 

Regards,

Karthik



Sample_9307e624.zip

Loader.
Live Chat Icon For mobile
Up arrow icon