O'Reilly logo

Pro ASP.NET 4.5 in C#, Fifth Edition by Mario Szpuszta, Matthew MacDonald, Adam Freeman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 8

image

SportsStore: Completing the Cart

In this chapter, we complete the user-facing parts of the SportsStore application by finishing off the shopping cart and adding support for submitting and validating orders.

Removing Unwanted Cart Items

We need to give the user the means to remove items from the basket. In Listing 8-1, you can see how we have added Remove buttons to the CartView.aspx Web Form for each item in the cart.

Listing 8-1.  Adding support for removing products from the cart

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="CartView.aspx.cs"    Inherits="SportsStore.Pages.CartView" MasterPageFile="∼/Pages/Store.Master" ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required