473,320 Members | 1,951 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

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
Nov 17 '05 #1
2 3464
You can clear your ViewState information programmatically 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" <Jk*******@NOhotmailSPAM.com> wrote in message
news:08****************************@phx.gbl...
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

Nov 17 '05 #2
You can clear your ViewState information programmatically 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" <Jk*******@NOhotmailSPAM.com> wrote in message
news:08****************************@phx.gbl...
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

Nov 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Tom Post | last post by:
I am doing a simple php header refresh -- header('refresh: 10; url=msgs.php'); that just does a call back to my script every 10 seconds. Things work great when the page is first loaded up, but if...
9
by: Mark | last post by:
I have a working PHP/MySQL application used for data entry. The data entry screen includes a "Save" button. The PHP code for this button looks like this: if (isset($_POST)) { if ($_POST ==...
4
by: Andrew Alger | last post by:
ok i have two forms. Customer.aspx and Parent_Searh.aspx. There is a button on Customer.aspx that when executed runs javascript code to open up parent_search as a popup. After the user searches...
6
by: laura | last post by:
I'm doing a page which gathers some text in the form of a text box in a <form>. This text is saved to a text file, notices.txt and I want to be able to display the saved text on the page, as soon...
10
by: tasmisr | last post by:
This is an old problem,, but I never had it so bad like this before,, the events are refiring when clicking the Browser refresh button. In the Submit button in my webform, I capture the server side...
1
by: ppatel | last post by:
Problem I have a problem with web image button control click event. The click event does not get trigger until it has not been clicked once or page refresh occures(which is fine). When click...
9
by: PK9 | last post by:
I'm having an issue with the "Refresh" of an asp.net page. The refresh is actually calling my last onClick event. I thought that asp.net was supposed to be stateless in that it shouldn't...
17
by: Jim Little | last post by:
Hello, I'm driving myself crazy either because I'm missing something about ASP.NET, or what I'm trying to do simply can't be done. First, I am not using session variables to track state. My...
3
by: Sameer | last post by:
I have a webpage that has a link button. This link button on click opens up a new page. This is what is happening: 1. Load the web page. 2. Click on the link. 3. Refresh the web-page. Result:...
3
by: =?Utf-8?B?cm9kY2hhcg==?= | last post by:
hi all, i betcha here's a question never asked before ;) i have a simple web form with a gridview and a button. the button doesn't do anything but a postback. i load up the gridview from the...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.