22 December, 2011

Disable Browser Back button in ASP.NET

Write following code all your back page prevent:

<head runat="server">
<title>Title page</title>
<script type = "text/javascript" >
function preventBack(){window.history.forward();}
setTimeout("preventBack()", 0);
window.onunload = function() { null };
</script>
</head>