Hey I have a radiobuttonlist and trying to set one of the radiobuttons to selected based on a session variable but proving impossible.
<asp:radiobuttonlist id="radio1" runat="server" AutoPostBack="True" OnSelectedIndexChanged="RadioButtonList1_SelectedIndexChanged">
<asp:listitem id="option1" runat="server" value="All"/>
<asp:listitem id="option2" runat="server" value="1" />
<asp:listitem id="option3" runat="server" value="2" />
</asp:radiobuttonlist>
I.e How can I set option2 to selected in code behind ?
See Question&Answers more detail:os