Repeaters do not do this by default.
However, gridviews do.
Personally, I hate GridViews, so I wrote a Paging / Sorting Repeater control.
The main steps:
- Repeater Management Subclass
- Add to it a private PagedDataSource
- Add Public PageSize Property
- Override Control.DataBind
- Store the Control.DataSource file in the PagedDataSource.
- Associate a Control.DataSource with a PagedDataSource
- Override Control.Render
- Call Base.Render ()
- Submit your paging links.
For walkthroughs you can try this link:
http://aspnet.4guysfromrolla.com/articles/081804-1.aspx
source share