Data Source Paging with the DataPager Control

You can take advantage of the DataPager control when performing data source paging. The page in Listing 14.10 contains a ListView control bound to a LinqDataSource control. Because the LinqDataSource control has its AutoPage property set to the value true, it performs paging on the database server.

Note

The LinqDataSource control and LINQ to SQL are discussed in Chapter 20, “Data Access with LINQ to SQL.”

Listing 14.10. DataPagerDataSource.aspx

images

images

So that you can verify that the paging is happening ...

Get ASP.NET 4 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.