<%@ Page Language="VB" AutoEventWireup="false" EnableEventValidation="false" CodeFile="PreRegister.aspx.vb" Inherits="Reports_PreRegister" %>

<!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:Button ID="btnExport" Text="Export To Excel" Width="100px" Visible="true" runat="server" />
        <asp:GridView ID="GridView1" runat="server" AllowPaging="True" AllowSorting="True"
            AutoGenerateColumns="False" BackColor="White" BorderColor="#336666" BorderStyle="Double"
            BorderWidth="3px" CellPadding="4" DataSourceID="SqlDataSource1" GridLines="Horizontal" PageSize="100">
            <FooterStyle BackColor="White" ForeColor="#333333" />
            <Columns>
                <asp:BoundField DataField="First_Name" HeaderText="First_Name" SortExpression="First_Name" />
                <asp:BoundField DataField="Last_Name" HeaderText="Last_Name" SortExpression="Last_Name" />
                <asp:BoundField DataField="Email" HeaderText="Email" SortExpression="Email" />
                <asp:BoundField DataField="Phone" HeaderText="Phone" SortExpression="Phone" />
                <asp:BoundField DataField="Address1" HeaderText="Address1" SortExpression="Address1" />
                <asp:BoundField DataField="Address2" HeaderText="Address2" SortExpression="Address2" />
                <asp:BoundField DataField="City" HeaderText="City" SortExpression="City" />
                <asp:BoundField DataField="State" HeaderText="State" SortExpression="State" />
                <asp:BoundField DataField="Zip" HeaderText="Zip" SortExpression="Zip" />
                <asp:BoundField DataField="CreatedDate" HeaderText="Date Created" SortExpression="CreatedDate" />
            </Columns>
            <RowStyle BackColor="White" ForeColor="#333333" />
            <SelectedRowStyle BackColor="#339966" Font-Bold="True" ForeColor="White" />
            <PagerStyle BackColor="#336666" ForeColor="White" HorizontalAlign="Center" />
            <HeaderStyle BackColor="#336666" Font-Bold="True" ForeColor="White" />
        </asp:GridView>
        <br />
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:Charter.Website.WS.CommerceEngineConnectionString %>"
            SelectCommand="SELECT Customer.[Identity].First_Name, Customer.[Identity].Last_Name, Customer.[Identity].Email, Customer.[Identity].Phone, [order].Address.Address1, [order].Address.Address2, [order].Address.City, [order].Address.State, [order].Address.Zip , [Customer].[Registration].CreatedDate FROM Customer.Registration INNER JOIN Customer.[Identity] ON Customer.Registration.Identity_ID = Customer.[Identity].Identity_ID INNER JOIN [order].Address ON Customer.Registration.Address_ID = [order].Address.Address_Table_ID">
        </asp:SqlDataSource>
    
    </div>
    </form>
</body>
</html>
