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

RadGrid custom paging and VirtualItemCount

2 Answers 116 Views
DataPager
This is a migrated thread and some comments may be shown as answers.
Maria
Top achievements
Rank 1
Maria asked on 18 Oct 2013, 03:18 PM
Hi everyone,

I am using custom paging for a Radgrid and although everything seems to be working out fine, I can't get the VirtualItemCount attribute of the radGrid to obtain the real value of the records that are returned from the datasource.
The radgrid loads with a typical value that is hard coded and the one i assign programmatically appears after i click on another page.
I can see that it succesfully sets the correct value but i guess the grid is already loaded.
The grid is connected with a search form and this is a problem when the search query changes. The pager appears to have the same results as the previous query although the grid displays the correct ones. How can I resolve that?

Thanx, Maria.

2 Answers, 1 is accepted

Sort by
0
Maria
Top achievements
Rank 1
answered on 21 Oct 2013, 12:36 PM
Ok, i will rephrase the question since it appears that there is a solution to my question.

When I am not using custom paging the rad grid gets the number of the results returned from the data source .

When I am using custom paging the rad grid cannot get the real value  of the items when i assign it programmatically, instead it holds on to the virtualItemCount that it was set with from the beginning.

So apparently there is a way for tha pager to get the correct number after loading. Can someone from telerik help me on this?

I need to understand how the property virtualCount in the paging Manager is set because I believe it is what is being used.
0
Maria
Top achievements
Rank 1
answered on 22 Oct 2013, 12:02 PM
This is partially resolved.
I have used the custom paging based on the objectDataSource methods select and selectCount and it works fine.
Tags
DataPager
Asked by
Maria
Top achievements
Rank 1
Answers by
Maria
Top achievements
Rank 1
Share this question
or