Hi,
How can we stop user to click back button in ASP.NET?
Stop User To Click Back Button In ASP.NET
4 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Sukesh MarlaRank #461 · 5.4K reputationPosted Aug 16, 2012, 7:39 AM EDT
Make sure to check this is correct answer
Sukesh MarlaRank #461 · 5.4K reputationPosted Aug 14, 2012, 8:57 AM EDT
1.Disable it
2.set it OnClientClick property to "javascript:return false;"
Or even
in javascript create function as
function CheckAndDisable()
{
//If need to disable
return false;
//else
return true;
}
...
And Set OnClientClick to "javascript:return CheckAndDisable();"
tom linker86 reputationPosted Aug 16, 2012, 2:48 AM EDT
please explain with an example.
tom linker86 reputationPosted Aug 17, 2012, 2:46 AM EDT