<%@ Page Language="C#" AutoEventWireup="true" CodeFile="EditDeleteButtons.aspx.cs" Inherits="EditDeleteButtons" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
    <asp:ScriptManager ID="ScriptManager" runat="server"></asp:ScriptManager>
    <telerik:RadGrid ID="RadGrid1" DataSourceID="SessionDataSource1" runat="server" Width="900px"
            PageSize="20" AllowSorting="True" AllowMultiRowSelection="True" Skin="Outlook"
             
            AllowPaging="True" AutoGenerateColumns="true" AutoGenerateEditColumn="true" OnColumnCreated="RadGrid1_ColumnCreated" OnItemCreated="RadGrid1_ItemCreated" OnPreRender="RadGrid1_PreRender" 
            >
            <PagerStyle Mode="NextPrevNumericAndAdvanced"></PagerStyle>
            <MasterTableView Width="100%" DataSourceID="SessionDataSource1" 
            EditFormSettings-EditFormType="AutoGenerated" CommandItemDisplay="Top">
                <Columns>
                </Columns>
            </MasterTableView>
        </telerik:RadGrid>
        <br/>
        <asp:SqlDataSource ID="SessionDataSource1" ConnectionString="<%$ ConnectionStrings:NorthwindConnectionString %>" 
            SelectCommand="SELECT Customers.CustomerID, Country, City, CompanyName, ContactName, Count(Orders.OrderID) as TotalOrders, Sum(OD.Quantity * OD.UnitPrice - Discount) as TotalAmount FROM Customers, Orders, [Order Details] OD Where (Orders.CustomerID = Customers.CustomerID) and (OD.OrderID = Orders.OrderID) Group By Customers.CustomerID, Country, City, CompanyName, ContactName"
            runat="server"></asp:SqlDataSource>
    
    </div>
    </form>
</body>
</html>
