Retaining the values of web form controls when back button is clicked

Anjali Agarwal 1,531 Reputation points
2021-09-17T01:23:55.263+00:00

I have several radio button list on my page and inside each list, I have several list items. I need to retrieve the radio button values when the back button is clicked. One way, I can do this store the values in session variables, but I was wondering if there is any easier way to store the values and then retrieve them when back button is clicked. All these radio button list are inside the Update panel and Content template.

<asp:UpdatePanel ID="updatePanel1" runat="server">
            <ContentTemplate>
 <asp:RadioButtonList CssClass="radioBL"  ID="rdbRiver" runat="server" OnSelectedIndexChanged="rdbRiverside_indexchanged" AutoPostBack="true" >
                                <asp:ListItem Value="Yes">Yes</asp:ListItem>
                                <asp:ListItem Value="No">No</asp:ListItem>
             </asp:RadioButtonList>
 <ContentTemplate>
 </updatePanel>

any help will be greatly appreciated
ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
3,597 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.