This is a migrated thread and some comments may be shown as answers.

progressive scroll in treeview

3 Answers 50 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Balsuyambu
Top achievements
Rank 1
Balsuyambu asked on 31 Oct 2012, 04:52 AM
Hi

I want to implement progressive scrolling funcionality in silverlight telerik treeview.

Initially set of items shall be added in the treeview (10 Items and child items of 10 items) and then item shall be added while scrolling the scroll viewer.

is it possible in treeview?

Thanks
Balsuyambu

3 Answers, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 31 Oct 2012, 04:08 PM
Hello Balsuyambu,

The RadTreeView UI Virtualizaiton feature generates the item containers as they come into view thus creating a progressive scrolling. You can find more information about the feature in our documentation or take a look at this demo where you can see it in action.

Please let me know if this is what you have in mind.

All the best,
Tina Stancheva
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Balsuyambu
Top achievements
Rank 1
answered on 01 Nov 2012, 06:11 AM

Hi Tina,

thanks for your clarifications.

We used RadTreeViewItem to add nodes into the RadTreeView and not binding any object. Please find below the sample.

RadTreeViewItem rtvi1 = new RadTreeViewItem();

 

rtvi1.Header =

 

"Node 1";

 

 

 

RadTreeViewItem rtvi2 = new RadTreeViewItem();

 

rtvi2.Header =

 

"Node 2";

 

 

 

RadTreeView1.Items.Add(rtvi1);

 

RadTreeView1.Items.Add(rtvi2);

 

 

In this case, if IsVirtualizing="True", can i get the expected behaviours that means what are the nodes i see in the view that only loaded and when i scroll, remaining nodes will be added.

thanks
Balsuyambu S.

0
Tina Stancheva
Telerik team
answered on 05 Nov 2012, 09:08 AM
Hi Balsuyambu,

The UI Virtualizaiton feature is only available when the RadTreeView's content is generated through a databinding operation. This is due to the fact that the UI virtualization generates containers of type RadTreeViewItem for each data item from the ItemsSource collection based on the properties of that data item and the binding definitions. However, when you create the RadTreeViewItems on your own, the control can't dynamically create or remove them as you need to manually set the information you need to provide in each RadTreeViewItem.

And in cases where the RadTreeView is used to display large lists, we recommend using a databinding approach and taking advantage of the virtualizaiton feature.

Kind regards,
Tina Stancheva
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
TreeView
Asked by
Balsuyambu
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
Balsuyambu
Top achievements
Rank 1
Share this question
or