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

Add DataPager to children

15 Answers 99 Views
TreeListView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Tim
Top achievements
Rank 1
Tim asked on 16 Mar 2012, 12:33 PM
Hello telerik!

I am using the RadTreeListView. One node can have A LOT of children! I want to use the RadDataPager to get rid of performance problems! I tried to add it - but without success. I am using this:
<telerik:RadTreeListView.ChildTableDefinitions>
     <telerik:TreeListViewTableDefinition ItemsSource="{Binding Children}"/>
</telerik:RadTreeListView.ChildTableDefinitions>

So I don't want the pager to be visible on the root nodes - only for child nodes.
How can I achieve this. Any help?

As this is important to me, I thank you for any help!!!
All the best,
Tim.

15 Answers, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 16 Mar 2012, 01:15 PM
Hello,

I am afraid that what your are trying to achieve is not possible. 

RadDataPager is a stand-alone independent control and cannot be added to other controls in the sense that you describe. RadDataPager is a complete equivalent of the standard toolkit DataPager control provided by Microsoft. The only difference is that it is themed and styled as the other Telerik controls.

Here is what RadDataPager is capable of. Unfortunately, you cannot somehow insert it inside RadTreeListView. RadDataPager can only page the top-level collection of RadTreeListView.

Kind regards,
Ross
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Tim
Top achievements
Rank 1
answered on 19 Mar 2012, 10:05 AM
0
Rossen Hristov
Telerik team
answered on 19 Mar 2012, 10:26 AM
Hi,

RadTreeListView is a different control from RadTreeView which is a HeaderedItemsControl and supports HierarchicalDataTemplates. On the other hand, RadTreeListView is in fact a RadGridView in disguise and cannot handle the same scenarios as RadTreeView does.

Unfortunately, I do not think that placing pagers inside RTLV would be possible. Maybe you should use RadTreeView instead of RadTreeListView.

Kind regards,
Ross
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Tim
Top achievements
Rank 1
answered on 19 Mar 2012, 10:38 AM
Hi Ross,

thanks for your quick reply! Unfortunately I need to display additional information for each item so the radtreelistview is needed. If one wants to use the radtreelistview and has sometimes more than 10.000 child entries your suggestion is? Is there some build-in help? Any suggestions beside not to use telerik controls or cut data? Thanks again and a lot, Tim.
0
Vlad
Telerik team
answered on 19 Mar 2012, 10:42 AM
Hi,

 The only option we can suggest you is to use RadTreeView or RadGridView instead RadTreeListView to achieve your goal. 

Kind regards,
Vlad
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Tim
Top achievements
Rank 1
answered on 19 Mar 2012, 10:49 AM
Or is it perhaps possible to give the control all of the data but to say that it at a maximum should display the first 500 entries. If the sorting is changed, all the data needed is present and again only the first 500 entries are displayed. The used data can also be changed from the user. So if the data changes the control need to find out the new 500 entries... Is something like that perhaps possible? A big thanks to you all again! Tim.
0
Vlad
Telerik team
answered on 20 Mar 2012, 08:12 AM
Hi,

 You can limit your items if you simply assign desired chunk of your collection to the treelist ItemsSource. Later you can cancel the component default sorting and perform your own similar to this demo

Greetings,
Vlad
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Tim
Top achievements
Rank 1
answered on 20 Mar 2012, 09:04 AM
Hi Vlad,

thanks for your reply! I'll give it a try!
All the best,
Tim.
0
Tim
Top achievements
Rank 1
answered on 20 Mar 2012, 10:37 AM
One short question concerning this topic: Would it be a good idea to use a QueryableCollectionView? Perhaps with this I can achieve an "in memory paging"?
0
Tim
Top achievements
Rank 1
answered on 20 Mar 2012, 08:38 PM
Hello. I implemented the custom paging using a QueryableCollectionView. It works like a charm! Except one thing:The scrollbar is always jumping to the top, whenever the sorting or the current page is changed! I am not reassigning any datasource. Concerning the page flip I only call, for example, MoveToPreviousPage and that's it. Why does the scrollbar jump to the top??? Any ideas? It would be really great if there would be a solution! :)

All the best and a big thanks,
Tim.
0
Vlad
Telerik team
answered on 22 Mar 2012, 02:19 PM
Hi Tim,

Indeed this is the default behavior of RadGridView and RadTreeListView. The scrollbar will be reset to top on every Reset CollectionChange including sorting, paging, filtering and grouping.

Greetings,
Vlad
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Tim
Top achievements
Rank 1
answered on 22 Mar 2012, 02:25 PM
Ok. And how can I change this default behavior? Thanks!
0
Vlad
Telerik team
answered on 22 Mar 2012, 02:44 PM
Hello,

 I'm afraid that this cannot be changed. 

Kind regards,
Vlad
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
Tim
Top achievements
Rank 1
answered on 22 Mar 2012, 02:53 PM
But why isn't the scrollbar jumping in this demo: http://demos.telerik.com/silverlight/#GridView/CustomSorting
0
Vlad
Telerik team
answered on 22 Mar 2012, 03:25 PM
Hello Tim,

 Can you send us your application (via support ticket) to check it locally what's going on?

Kind regards,
Vlad
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Tags
TreeListView
Asked by
Tim
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Tim
Top achievements
Rank 1
Vlad
Telerik team
Share this question
or