Tuesday, July 15, 2008

How to Customize GridView Pager at Runtime Using ObjectDataSource

To display bulk amounts of data in a GridView, it's often better to use Paging concept. When creating a pageable GridView whose underlying data is coming from an ObjectDataSource, you'll need to ensure that your Business Logic Layer includes methods that have input parameters that specify how to create the Paging Details. The ObjectDataSource supports both the default and custom paging models.

Inorder to support custom paging, the Business Logic Layer must include some additional features. The underlying Buniness Logoc Layer class's SELECT method must accept 2 integer arguments, the first one specifying the maximum number of records to return and the second specifying the starting record index. To know how to do all this please visit the following website

http://msdn.microsoft.com/en-us/library/aa479347.aspx

Hope this help you a lot.

No comments: