2

I am trying to split content into pages and I am looking for the smartest way. So my controller send a model with for example 45 records I want to display them in 3 pages with 15 rows in each one of them with navigation buttons in the bottom.([1] , [2] ... like links) What should I do? Split the content in the controller and make 3 separates views with different names for example /Home/Action/page1.... /Home/Action/page2 ? Or there is smarter way to do this.

tereško
  • 58,060
  • 25
  • 98
  • 150
D.B.U.
  • 73
  • 1
  • 9
  • are you looking for somethink like grid – COLD TOLD Jan 22 '13 at 20:14
  • This question may help you http://stackoverflow.com/questions/8070030/the-easiest-way-for-paging-with-mvc3-c – Brandon Nicoll Jan 22 '13 at 20:16
  • Actually i can't use it as i expected... Is there a tutorial how to make it work i mean to display the content end to end tutorial... Because in the other question there's only the view code... And i'am encountering some problems implementing logic in controller maybe I should add some things in the model i don't know... I managed to display pages but only with the content from page 1..... – D.B.U. Jan 22 '13 at 21:58

1 Answers1

2

I got found what i was looking for here: Sorting, Filtering, and Paging with the Entity Framework in an ASP.NET MVC Application (3 of 10).

Alexander
  • 23,432
  • 11
  • 63
  • 73
D.B.U.
  • 73
  • 1
  • 9