Refresh button

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jeremy

    #1

    Refresh button

    I'm sure this has to be in an FAQ somewhere, but I
    couldn't find anything about it. When I click
    the "Refresh" button in my browser I preform the last HTTP
    method I did. Needless to say, this is not the
    functionality of a refresh button that I would like.

    When I click on "Refresh" I want the page to completely
    reload and drop all of the view state information it is
    currently holding and treat it like a brand new request.
    (Basically, like how a refresh does with classic ASP and
    HTML, etc.)

    Is there any way to get around this new "feature" of
    ASP.NET?

    Thanks,
    Jeremy
  • ASP.NET

    #2
    Re: Refresh button

    You can clear your ViewState information programmaticall y or you can turn it
    off if you don't want it at all. You could try detecting on Page_Load
    whether your code has "seen" the page in its current state and then skip any
    re-processing or you could try trapping the refresh event with javascript.
    I guess one question would be: why do you want to do this (or not do this,
    to be more precise)?

    Regards,
    Stephen

    "Jeremy" <Jknight12@NOho tmailSPAM.com> wrote in message
    news:085d01c366 19$fb8ddde0$a50 1280a@phx.gbl.. .[color=blue]
    > I'm sure this has to be in an FAQ somewhere, but I
    > couldn't find anything about it. When I click
    > the "Refresh" button in my browser I preform the last HTTP
    > method I did. Needless to say, this is not the
    > functionality of a refresh button that I would like.
    >
    > When I click on "Refresh" I want the page to completely
    > reload and drop all of the view state information it is
    > currently holding and treat it like a brand new request.
    > (Basically, like how a refresh does with classic ASP and
    > HTML, etc.)
    >
    > Is there any way to get around this new "feature" of
    > ASP.NET?
    >
    > Thanks,
    > Jeremy[/color]


    Comment

    • ASP.NET

      #3
      Re: Refresh button

      You can clear your ViewState information programmaticall y or you can turn it
      off if you don't want it at all. You could try detecting on Page_Load
      whether your code has "seen" the page in its current state and then skip any
      re-processing or you could try trapping the refresh event with javascript.
      I guess one question would be: why do you want to do this (or not do this,
      to be more precise)?

      Regards,
      Stephen

      "Jeremy" <Jknight12@NOho tmailSPAM.com> wrote in message
      news:085d01c366 19$fb8ddde0$a50 1280a@phx.gbl.. .[color=blue]
      > I'm sure this has to be in an FAQ somewhere, but I
      > couldn't find anything about it. When I click
      > the "Refresh" button in my browser I preform the last HTTP
      > method I did. Needless to say, this is not the
      > functionality of a refresh button that I would like.
      >
      > When I click on "Refresh" I want the page to completely
      > reload and drop all of the view state information it is
      > currently holding and treat it like a brand new request.
      > (Basically, like how a refresh does with classic ASP and
      > HTML, etc.)
      >
      > Is there any way to get around this new "feature" of
      > ASP.NET?
      >
      > Thanks,
      > Jeremy[/color]


      Comment

      Working...