Results 1 to 3 of 3

Thread: Back Button

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Dec 2009
    Location
    Milan
    Posts
    810

    Back Button

    I've got a form that when a button is clicked it sends the data to a database and returns a record number. how can i stop the user form using the back button and hitting enter again?

  2. #2
    Learning .Net danasegarane's Avatar
    Join Date
    Aug 2004
    Location
    VBForums
    Posts
    5,853

    Re: Back Button

    You can force the cache to expires .In the page load event add this code

    Code:
    Page.Response.Cache.SetCacheability(HttpCacheability.NoCache)
    Response.Cache.SetExpires(DateTime.Now)
    Please mark you thread resolved using the Thread Tools as shown

  3. #3
    PowerPoster gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Back Button

    Hello,

    Although there are "hacky" ways to take over the back button in the browser, this can be done using JavaScript, I would highly recommend that you don't do this. This makes for an inconsistent experience for the user, and it not advisable.

    Gary

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width