I am designing a page containing a gridview that takes the data from a dataSource
the data are evaluation questions (20 questions) and the answers are degree of five represented by radiobuttons

I added the radio buttons to the gridview as template item

Like this :

<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
CellPadding="4" DataKeyNames="question#" DataSourceID="SqlDataSource" ForeColor="#333333"
GridLines="None" Style="z-index: 102; right: 2px; position: relative; top: -41px" Width="649px" Height="199px">
<FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<Columns>
<asp:BoundField DataField="question#" HeaderText="no " InsertVisible="False" ReadOnly="True"
SortExpression="question#" />
<asp:BoundField DataField="question" HeaderText="Question" SortExpression="question">
<ItemStyle HorizontalAlign="Right" />
</asp:BoundField>
<asp:TemplateField HeaderText="answers">
<ItemTemplate>
<asp:RadioButton ID="btn5" Text="excellent" runat="server" Font-Size="X-Small" GroupName="answer"/>
<asp:RadioButton ID="btn4" Text="v good" runat="server" Font-Size="X-Small" GroupName="answer"/>
<asp:RadioButton ID="btn3" Text="good" runat="server" Font-Size="X-Small" GroupName="answer"/>
<asp:RadioButton ID="btn2" Text="weekly good" runat="server" Font-Size="X-Small" GroupName="answer" />
<asp:RadioButton ID="btn1" Text="bad" runat="server" Font-Size="X-Small" GroupName="answer" />
</ItemTemplate>
<ItemStyle Width="230px" />
</asp:TemplateField>
</Columns>
<RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
<EditRowStyle BackColor="#999999" />
<SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
<PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
<HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<AlternatingRowStyle BackColor="White" ForeColor="#284775" />

</asp:GridView>

but now I want to get the answer of each question but I have no idea how that could be accomplished :(

if some one has any idea please help me :)

This article has been dead for over six months. Start a new discussion instead.