<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>

<%@ 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>
    <link href="TestSkin/Input.TestSkin.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
        <telerik:RadCodeBlock ID="rcb" runat="server">

            <script type="text/javascript">    
       
             
            </script>

        </telerik:RadCodeBlock>
        <asp:ScriptManager runat="server" ID="ScriptManager1">
        </asp:ScriptManager>
      
        
         <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
            <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="RadGrid1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadGrid1" LoadingPanelID="RadAjaxLoadingPanel1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
            </AjaxSettings>
        </telerik:RadAjaxManager>
        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="75px" Width="75px" Transparency="20">
            <img alt="Loading..." src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' style="border:0;" />
        </telerik:RadAjaxLoadingPanel>
        <telerik:GridNumericColumnEditor ID="GridNumericColumnEditor1" runat="server">
            <NumericTextBox MaxLength="4" EmptyMessage="Ext." runat="server">
                <NumberFormat GroupSeparator="" />
            </NumericTextBox>
        </telerik:GridNumericColumnEditor>
        <telerik:RadGrid DataSourceID="AccessDataSource1" Skin="Vista" AllowAutomaticDeletes="True"
            AllowAutomaticInserts="True" AllowAutomaticUpdates="True" ID="RadGrid1" runat="server" GridLines="None">
            <MasterTableView DataKeyNames="EmployeeID" Width="100%" CommandItemDisplay="Top"
                AutoGenerateColumns="False" DataSourceID="AccessDataSource1">
                <Columns>
                
                <telerik:GridEditCommandColumn>
                </telerik:GridEditCommandColumn>
                
                    <telerik:GridBoundColumn DataField="EmployeeID" DataType="System.Int32" HeaderText="EmployeeID"
                        ReadOnly="True" SortExpression="EmployeeID" UniqueName="EmployeeID">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="LastName" HeaderText="LastName" SortExpression="LastName"
                        UniqueName="LastName">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="FirstName" HeaderText="FirstName" SortExpression="FirstName"
                        UniqueName="FirstName">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Title" HeaderText="Title"
                        SortExpression="Title" UniqueName="Title">
                    </telerik:GridBoundColumn>
                    
                    <telerik:GridDropDownColumn DataField="TitleOfCourtesy" DataSourceID="AccessDataSource2"
                     ListTextField="TitleOfCourtesy" ListValueField="TitleOfCourtesy"
                     DropDownControlType="RadComboBox" HeaderText="TitleOfCourtesy">
                    </telerik:GridDropDownColumn>                    
                    
                    <telerik:GridBoundColumn DataField="BirthDate" DataType="System.DateTime" HeaderText="BirthDate"
                        SortExpression="BirthDate" UniqueName="BirthDate">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="HireDate" DataType="System.DateTime" HeaderText="HireDate"
                        SortExpression="HireDate" UniqueName="HireDate">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Address" HeaderText="Address" SortExpression="Address"
                        UniqueName="Address">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="City" HeaderText="City" SortExpression="City"
                        UniqueName="City">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Region" HeaderText="Region" SortExpression="Region"
                        UniqueName="Region">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="PostalCode" HeaderText="PostalCode" SortExpression="PostalCode"
                        UniqueName="PostalCode">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Country" HeaderText="Country" SortExpression="Country"
                        UniqueName="Country">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="HomePhone" HeaderText="HomePhone" SortExpression="HomePhone"
                        UniqueName="HomePhone">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Extension" HeaderText="Extension" SortExpression="Extension"
                        UniqueName="Extension">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Photo" HeaderText="Photo" SortExpression="Photo"
                        UniqueName="Photo">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Notes" HeaderText="Notes" SortExpression="Notes"
                        UniqueName="Notes">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="ReportsTo" DataType="System.Int32" HeaderText="ReportsTo"
                        SortExpression="ReportsTo" UniqueName="ReportsTo">
                    </telerik:GridBoundColumn>
                </Columns>
                <RowIndicatorColumn>
                    <HeaderStyle Width="20px" />
                </RowIndicatorColumn>
                <ExpandCollapseColumn>
                    <HeaderStyle Width="20px" />
                </ExpandCollapseColumn>
                <EditFormSettings>
                    <EditColumn UniqueName="EditCommandColumn1">
                    </EditColumn>
                </EditFormSettings>
            </MasterTableView>
            <FilterMenu EnableTheming="True" Skin="Vista">
                <CollapseAnimation Duration="200" Type="OutQuint" />
            </FilterMenu>
        </telerik:RadGrid>
        <!-- content end -->
        
        <asp:AccessDataSource runat="server" ID="AccessDataSource1" DataFile="~/App_Data/Nwind.mdb" DeleteCommand="DELETE FROM [Employees] WHERE [EmployeeID] = ?" InsertCommand="INSERT INTO [Employees] ([EmployeeID], [LastName], [FirstName], [Title], [TitleOfCourtesy], [BirthDate], [HireDate], [Address], [City], [Region], [PostalCode], [Country], [HomePhone], [Extension], [Photo], [Notes], [ReportsTo]) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)" SelectCommand="SELECT * FROM [Employees]" UpdateCommand="UPDATE [Employees] SET [LastName] = ?, [FirstName] = ?, [Title] = ?, [TitleOfCourtesy] = ?, [BirthDate] = ?, [HireDate] = ?, [Address] = ?, [City] = ?, [Region] = ?, [PostalCode] = ?, [Country] = ?, [HomePhone] = ?, [Extension] = ?, [Photo] = ?, [Notes] = ?, [ReportsTo] = ? WHERE [EmployeeID] = ?">
            <DeleteParameters>
                <asp:Parameter Name="EmployeeID" Type="Int32" />
            </DeleteParameters>
            <UpdateParameters>
                <asp:Parameter Name="LastName" Type="String" />
                <asp:Parameter Name="FirstName" Type="String" />
                <asp:Parameter Name="Title" Type="String" />
                <asp:Parameter Name="TitleOfCourtesy" Type="String" />
                <asp:Parameter Name="BirthDate" Type="DateTime" />
                <asp:Parameter Name="HireDate" Type="DateTime" />
                <asp:Parameter Name="Address" Type="String" />
                <asp:Parameter Name="City" Type="String" />
                <asp:Parameter Name="Region" Type="String" />
                <asp:Parameter Name="PostalCode" Type="String" />
                <asp:Parameter Name="Country" Type="String" />
                <asp:Parameter Name="HomePhone" Type="String" />
                <asp:Parameter Name="Extension" Type="String" />
                <asp:Parameter Name="Photo" Type="String" />
                <asp:Parameter Name="Notes" Type="String" />
                <asp:Parameter Name="ReportsTo" Type="Int32" />
                <asp:Parameter Name="EmployeeID" Type="Int32" />
            </UpdateParameters>
          
        </asp:AccessDataSource>             
        <asp:AccessDataSource runat="server" ID="AccessDataSource2" DataFile="~/App_Data/Nwind.mdb" SelectCommand="SELECT DISTINCT [TitleOfCourtesy] FROM [Employees]"></asp:AccessDataSource>
        
    </form>
</body>
</html>
