<%@ 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>
        &nbsp;&nbsp;<br />
        <telerik:RadGrid ID="RadGrid1" runat="server" AllowAutomaticDeletes="True" AllowAutomaticInserts="True"
            AllowAutomaticUpdates="True" DataSourceID="AccessDataSource1" GridLines="None">
            <MasterTableView AutoGenerateColumns="False" DataKeyNames="ID" DataSourceID="AccessDataSource1">
                <RowIndicatorColumn>
                    <HeaderStyle Width="20px" />
                </RowIndicatorColumn>
                <ExpandCollapseColumn>
                    <HeaderStyle Width="20px" />
                </ExpandCollapseColumn>
                <Columns>
                    <telerik:GridEditCommandColumn>
                    </telerik:GridEditCommandColumn>
                    <telerik:GridBoundColumn DataField="ID" DataType="System.Int32" HeaderText="ID" ReadOnly="True"
                        SortExpression="ID" UniqueName="ID">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Name" HeaderText="Name" SortExpression="Name"
                        UniqueName="Name">
                    </telerik:GridBoundColumn>
                    <telerik:GridTemplateColumn UniqueName="Male" HeaderText="Male">
                        <ItemTemplate>
                            <asp:RadioButton ID="RadioButton1" Enabled="false" runat="server" Checked='<%#Eval("Male")%>' />
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:RadioButton ID="RadioButton2" GroupName="MF" Checked='<%#Bind("Male")%>' runat="server" />
                        </EditItemTemplate>
                    </telerik:GridTemplateColumn>
                    <telerik:GridTemplateColumn UniqueName="Female" HeaderText="Female">
                        <ItemTemplate>
                            <asp:RadioButton ID="RadioButton3" Enabled="false" runat="server"  Checked='<%#Eval("Female")%>'/>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:RadioButton ID="RadioButton4" GroupName="MF" Checked='<%#Bind("Female")%>' runat="server" />
                        </EditItemTemplate>
                    </telerik:GridTemplateColumn>
                </Columns>
                <EditFormSettings>
                    <EditColumn UniqueName="EditCommandColumn1">
                    </EditColumn>
                </EditFormSettings>
            </MasterTableView>
            <FilterMenu EnableTheming="True">
                <CollapseAnimation Duration="200" Type="OutQuint" />
            </FilterMenu>
        </telerik:RadGrid><asp:AccessDataSource ID="AccessDataSource1" runat="server" DataFile="~/App_Data/Nwind.mdb"
            DeleteCommand="DELETE FROM [Test] WHERE [ID] = ?" InsertCommand="INSERT INTO [Test] ([ID], [Name], [Male], [Female]) VALUES (?, ?, ?, ?)"
            SelectCommand="SELECT [ID], [Name], [Male], [Female] FROM [Test]" UpdateCommand="UPDATE [Test] SET [Name] = ?, [Male] = ?, [Female] = ? WHERE [ID] = ?">
            <DeleteParameters>
                <asp:Parameter Name="ID" Type="Int32" />
            </DeleteParameters>
            <UpdateParameters>
                <asp:Parameter Name="Name" Type="String" />
                <asp:Parameter Name="Male" Type="Boolean" />
                <asp:Parameter Name="Female" Type="Boolean" />
                <asp:Parameter Name="ID" Type="Int32" />
            </UpdateParameters>
            <InsertParameters>
                <asp:Parameter Name="ID" Type="Int32" />
                <asp:Parameter Name="Name" Type="String" />
                <asp:Parameter Name="Male" Type="Boolean" />
                <asp:Parameter Name="Female" Type="Boolean" />
            </InsertParameters>
        </asp:AccessDataSource>
    </form>
</body>
</html>
