Project Description
The PagerHtmlHelper allows you to quickly and simply add a paging control to any MVC 2 web application.

Usage:

  1. Download the 3 files in the project
  2. Reference "MvcUserControlHtmlHelpers.dll" in your MVC 2 Web Application
  3. Add "Pager.ascx" to your App_Code folder - If you dont have an App_Code folder, just create one
  4. Add the stylesheet to your html's head section
  5. Write the following code into any of your views:
<% Html.RenderPager([TotalItemCountHere],
[PageSize],
[PageIndex],
Request.Url.Query,
[BaseUrl - Can be relative]); %>
This will insert the pager control wherever you place the code.

Find a complete article about how to use this control at http://benjii.me/2010/07/simple-mvc-2-pager-control-pagerhtmlhelper/

Last edited Jul 26, 2010 at 11:45 AM by bjcull, version 6