I have the following 2 methods in my ObjectDataSource constucted class
public virtual IList<
TEntity
> ODSFindAll(int startRow, int pageSize, string sortExpression, string filterExpression)
public virtual int ODSCountAll(string sortExpression, string filterExpression)
Both these methods are called fine by the ObjectDataSource connected to the RadGrid when 'sorting columns' however when filtering the ODSFindAll method is called with pageSize = 2147483647. It shouldn't be as I can see ODSCountAll being called and returning the correct count for the filter.
Without filtering in RadGrid the pageSize value is 10 and RadGrid lets the ODSFindAll method sort the data return just the 10 rows. It calls the ODSCountAll method to find out how many page rows there actually are.
With sorting & filtering in RadGrid the pageSize value jumps to 2147483647 - which is wasteful and unessesary because I can see it correctly passing both the sortorder and filterexpression correctly. Why is it doing this??
In another posting you suggest setting MaximumRows on the datasource but this causes problems on the 'page summary' where it incorrectly states "500 items in 32 pages" (where 500 is maximumrows and not the count returned by ODSCountAll when filtering.
The other post I refer to is :
http://www.telerik.com/community/forums/aspnet/grid/filtering-and-paging-simultaneously-in-objectdatasource.aspx
Regards, Darren
<UPDATE>
I also found this post http://www.telerik.com/community/forums/aspnet-ajax/grid/maximum-rows-parameter-with-filtering.aspx with no clear outcome..