Solved

ASP.Net MVC 4 C# -- Details Paging (Previous/Next)

Posted on 2013-05-31
2
603 Views
Last Modified: 2015-12-08
How can I add "Previous/Next" buttons to the below
Details.cshtml code so only "Classic" Genre
items can be viewed ?
------------------------------------------------------
Steps
 1. run MvcMusicStore APP
 2. click on the "Classic" Genre
 3. below \Views\Store\GenreMenu.cshtml displays

      @model IEnumerable<MvcMusicStore.Models.Genre>
      <ul id="categories">
          @foreach (var genre in Model)
          {
        <li>@Html.ActionLink(genre.Name,
                "Browse", "Store",
                new { Genre = genre.Name }, null)
        </li>
          }
      </ul>
 4. click on an item
 5. below \Views\Store\Details.cshtml displays
------------------------------------------------------

@model MvcMusicStore.Models.Album

@{
    ViewBag.Title = "Album - " + Model.Title;
}

<h2>@Model.Title</h2>

<p>
    <img alt="@Model.Title" src="@Model.AlbumArtUrl" />
</p>


<div id="album-details">
    <p>
        <em>Genre:</em>
        @Model.Genre.Name
    </p>
    <p>
        <em>Artist:</em>
        @Model.Artist.Name
    </p>
    <p>
        <em>Price:</em>
        @String.Format("{0:F}", Model.Price)
    </p>
    <p class="button">
        @Html.ActionLink("Add to cart", "AddToCart",
        "ShoppingCart", new { id = Model.AlbumId }, "")
    </p>
</div>
------------------------------------------------------
Something like the below, but want as easy as possible
  ** http://stackoverflow.com/questions/1522622/creating-a-detailsview-pager-in-asp-net-mvc
  ** http://stackoverflow.com/questions/9496837/go-to-next-record-from-asp-net-mvc-details-view
  ** http://stackoverflow.com/questions/13298605/filter-and-pagination-in-mvc-4
0
Comment
Question by:finance_teacher
2 Comments
 
LVL 19

Accepted Solution

by:
Manoj Patil earned 500 total points
ID: 39211413
0
 

Author Comment

by:finance_teacher
ID: 39212879
Below are two links I found.
Do you have any other links ?

http://forums.asp.net/t/1707072.aspx/1
http://en.webdiyer.com/MvcPager
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Class object 2 26
C# parent child form 5 17
Need a starter for ETL protocol? 4 39
Windows Media Player 2 11
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
As a trusted technology advisor to your customers you are likely getting the daily question of, ‘should I put this in the cloud?’ As customer demands for cloud services increases, companies will see a shift from traditional buying patterns to new…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now