O'Reilly logo

Learning ASP.NET 2.0 with AJAX by Dan Hurwitz, Jesse Liberty, Brian MacDonald

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

Source Code Listings

The style sheet, StyleSheet.css, is listed in Example 10-1.

The site map file, Web.sitemap, is listed in Example 10-7.

Cart Page

Example 10-12. Cart.aspx

<%@ Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false"
    CodeFile="Cart.aspx.vb" Inherits="Cart" title="Cart" %>
<%@ MasterType TypeName="MasterPage" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1"
        Runat="Server">
    <asp:SqlDataSource ID="sqlCart" runat="server"
        ConnectionString="<%$ ConnectionStrings:AdventureWorksConnectionString %>"
        SelectCommand= "select product.ProductID, product.Name,
                    product.ProductNumber, product.Color,
                    subcat.Name as SubcategoryName, cat.Name as CategoryName,
                    description.Description
                    from Production.Product product
                    join Production.ProductSubcategory subcat on
                        product.ProductSubcategoryID = subcat.ProductSubcategoryID
                    join Production.ProductCategory cat on
                        subcat.ProductCategoryID = cat.ProductCategoryID
                    join Production.ProductModel model on
                        product.ProductModelID = model.ProductModelID
                    join Production.ProductModelProductDescriptionCulture culture
                        on model.ProductModelID = culture.ProductModelID
                    join Production.ProductDescription description on
                        culture.ProductDescriptionID =
                            description.ProductDescriptionID ">
    </asp:SqlDataSource> <asp:GridView ID="gvCart" runat="server" DataSourceID="sqlCart" AllowPaging="True" AllowSorting="True" Width="100%" AutoGenerateColumns="False" HeaderStyle-CssClass="TableColumnHeading" RowStyle-CssClass="TableCells"> ...

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