"Page Can't be dispayed" page when "Browser" back button clicked !

Hi,

I am working on a bank application. If user tries to move back by using "Browser" i should get the below page message. Can you please let me know how can i achieve this by using sample code ?

Here is the information i should get in the page:

Warning: Page has Expired The page you requested was created using information you submitted in a form. This page is no longer available. As a security precaution, Internet Explorer does not automatically resubmit your information for you.

To resubmit your information and view this Web page, click the Refresh button.



Thanks,
Kishore
kishore_peddiAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

tusharashahCommented:
Put following code in your Page_Load event, that will prevent page from caching:

Response.Cache.SetCacheability(HttpCacheability.NoCache)

other optional statements you can try are:
           Response.ExpiresAbsolute = DateTime.Now.Subtract(new TimeSpan(1, 0, 0, 0)) ;
           Response.Expires = 0 ;
           Response.CacheControl = "no-cache" ;

-tushar

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
kishore_peddiAuthor Commented:


Still not working ! Any help ?

Thanks,
Kishore
aki4uCommented:
solution provided
aki4uCommented:
any specific reason for not accepting my answer?
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ASP.NET

From novice to tech pro — start learning today.