Master Page back button

Hi Expert,

There is a Back button in master page.
 <asp:Button ID="btnBack" runat="server" Text="Back" OnClientClick="history.back(); return false;" />  

It works in one page:
<%@ Page Language="C#" MasterPageFile="~/Dq.master" AutoEventWireup="true" CodeBehind="ReviewPage.aspx.cs" Inherits="ReviewPage" Title="Review Detail" %>

But it does not work in another page:
<%@ Page Language="C#" MasterPageFile="~/MyWeb.master" AutoEventWireup="true" CodeBehind="EmployeeFileDocuments.aspx.cs" Inherits="MyWeb.Reports.EmployeeFileDocuments" Title="Employee Documents Image Report" %>

I am not sure it is the following problem or not:

Sometimes I got the following error. Appreciated!

Webpage has expired
Most likely cause:
•The local copy of this webpage is out of date, and the website requires that you download it again.
Something to try:

  Click on the Refresh button on the toolbar to reload the page. After refreshing, you might need to navigate to the specific webpage again, or re-enter information.  

More information  More information  

If you continue to have this problem, try the following:
1.In Internet Explorer, click the Tools button , click Internet Options, and then click the Advanced tab.
2.Scroll down and clear the “Do not save encrypted pages to disk” option in the Security settings.
Who is Participating?
Bob LearnedCommented:
Are you doing anything with disabling the cache for the page?

protected void Page_Init(object sender, EventArgs e)
    Response.AppendHeader("Cache-Control", "no-cache");


protected void Page_Init(object sender, EventArgs e)
    Response.AppendHeader("Cache-Control", "no-cache, no-store, must-revalidate");
    Response.AppendHeader("Pragma", "no-cache");
    Response.AppendHeader("Expires", "0");
jssong2000Author Commented:
Yes. I found the code:
Response.Cache.SetNoStore(). This is culprit.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.