title: How can I disable Browser's Cache throughout my web application in asp.net 4.0?
body: <p>I'm facing issue because of Browser's cache in We Application.</p>
  
  <p>On LogoutButton Click I clear the Session and Cache in the following way.</p>
  
  <pre><code>Session.Clear();
  Session.RemoveAll();
  Session.Abandon();
  // Code disables caching by browser.
  Response.Cache.SetCacheability(HttpCacheability.NoCache);
  Response.Cache.SetExpires(DateTime.UtcNow.AddHours(-1));
  Response.Cache.SetNoStore();
  Response.Redirect("LoginPage.aspx", false);
  </code></pre>
  
  <p>and I'm disabling the Back Button also.</p>
  
  <p>But If I access the History, User is able to get access to all the pages even after LogOut also.</p>
  
  <p>In the latest Version of FireFox I have observed that It does not allow for Back Button, But When U long press the Back Button Firefox shows You the History means Previous Pages and When User clicks on it , It says some try again message and When User clicks on Try Again Message, then User is redirected to the given Pages and On Web Application It shows the Name of Old User name, for which I have just logged out recently.</p>
  
  <p>In Google Chrome also I'm facing the same Issue.</p>
  
  <p>One More thing I have observed that, in FireFox When User clicks Try Again. It hits the Login_ButtonClick Method of Login Page and Submits the credentials and that is why User is able to log in.</p>
  
  <p>So I have come to this point and I have to find out some way so that browser does not cache my web application page because I'm not using Caching in application and performance is not a concern for me.</p>
  
  <p>Or If I can do this in some other way, please let me know.</p>