Method 1) Client Side Javascript
========================
<script type = "text/javascript" >
function disableBackButton()
{
window.history.forward();
}
setTimeout("disableBackButton()", 0);
</script>call disableBackButton() onload of the page Method 2) Codebehind ================= Override OnPreRender and register the above script Method 3) Disabling browser caching =========================== By disabling browser caching or cache either in Page_load event or in Page_Init event checkout this for details http://csharpdotnetfreak.blogspot.com/2009/04/disable-browser-back-button-javascript.html On Fri, Nov 27, 2009 at 4:58 PM, pallavi kondapure <[email protected] > wrote: > Thanks for the info.. > Could you please suggest the solution for this.... > > Regards > > On Tue, Nov 24, 2009 at 6:16 PM, Raghupathi Kamuni < > [email protected]> wrote: > >> Browser "Back Button" is not meant to go forward....... >> >> >> On Tue, Nov 24, 2009 at 2:05 PM, pallavi kondapure < >> [email protected]> wrote: >> >>> >>> Hi All, >>> >>> I have a web page ,basically content page that is using AJAX controls(in >>> .Net 3.5) ,Now my requirement is to disable back button in the browser .I >>> have put >>> >>> window.history.forward(); >>> I am calling this code on onload in javascript >>> window .onload >>> >>> This code works the first time the page is loaded.but when i click >>> submit button a gridview is shown in the same page ,then when I click on the >>> Back Button of the browser the following message appears >>> >>> "*Warning: Page has Expired "* >>> >>> I want to show the same page when the user clicks the browser Back >>> button. >>> Kindly Suggest >>> >>> Thanks in advance >>> Pallavi.K >>> >>> >>> >>> >>> >>> >> >> >
