I experimented with a snippet of JavaScript that will display a "Please
Wait" message and graphic while the results of a cgi script is running (the
script grabs a bunch of data and formats it in a table). Once the page has
loaded, the script clears the message and graphic. It works fine, however
if you click the button on the browser to cancel the page load, the browser
will render what it can of the table and the "Please Wait" message and
graphic is still displayed.
Is there an event that can be acted upon when the user clicks the browser's
cancel button that would allow me to turn the display of the message off?
Thanks 7 4637
John Gault said the following on 11/27/2007 12:05 AM:
I experimented with a snippet of JavaScript that will display a "Please
Wait" message and graphic while the results of a cgi script is running (the
script grabs a bunch of data and formats it in a table). Once the page has
loaded, the script clears the message and graphic. It works fine, however
if you click the button on the browser to cancel the page load, the browser
will render what it can of the table and the "Please Wait" message and
graphic is still displayed.
Is there an event that can be acted upon when the user clicks the browser's
cancel button that would allow me to turn the display of the message off?
No. Clicking "Cancel" tells the browser to stop doing *anything* in the
page and to simply display what it can. Imagine though, if you could
trap the Cancel event, and a page author decided to re-call the
window.onload handler every time you did, where would you ever get to?
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
On Nov 27, 6:04 am, Randy Webb <HikksNotAtH...@aol.comwrote:
John Gault said the following on 11/27/2007 12:05 AM:
I experimented with a snippet of JavaScript that will display a "Please
Wait" message and graphic while the results of a cgi script is running (the
script grabs a bunch of data and formats it in a table). Once the page has
loaded, the script clears the message and graphic. It works fine, however
if you click the button on the browser to cancel the page load, the browser
will render what it can of the table and the "Please Wait" message and
graphic is still displayed.
Is there an event that can be acted upon when the user clicks the browser's
cancel button that would allow me to turn the display of the message off?
No. Clicking "Cancel" tells the browser to stop doing *anything* in the
page and to simply display what it can. Imagine though, if you could
trap the Cancel event, and a page author decided to re-call the
window.onload handler every time you did, where would you ever get to?
He just wants to hide the status message, not reload the entire
procedure.
John, this should work for you http://www.java2s.com/Code/JavaScrip...StopButton.htm
--
Kailash Nadh | http://kailashnadh.name
Kailash Nadh said the following on 11/27/2007 4:58 AM:
On Nov 27, 6:04 am, Randy Webb <HikksNotAtH...@aol.comwrote:
>John Gault said the following on 11/27/2007 12:05 AM:
>>I experimented with a snippet of JavaScript that will display a "Please Wait" message and graphic while the results of a cgi script is running (the script grabs a bunch of data and formats it in a table). Once the page has loaded, the script clears the message and graphic. It works fine, however if you click the button on the browser to cancel the page load, the browser will render what it can of the table and the "Please Wait" message and graphic is still displayed. Is there an event that can be acted upon when the user clicks the browser's cancel button that would allow me to turn the display of the message off?
No. Clicking "Cancel" tells the browser to stop doing *anything* in the page and to simply display what it can. Imagine though, if you could trap the Cancel event, and a page author decided to re-call the window.onload handler every time you did, where would you ever get to?
He just wants to hide the status message, not reload the entire
procedure.
Who said he did? I said there is a potential for abuse if you can.
John, this should work for you http://www.java2s.com/Code/JavaScrip...StopButton.htm
Test it in a non-IE browser.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
"Kailash Nadh" <ka**********@gmail.comwrote in message
news:35**********************************@o6g2000h sd.googlegroups.com...
On Nov 27, 6:04 am, Randy Webb <HikksNotAtH...@aol.comwrote:
>John Gault said the following on 11/27/2007 12:05 AM:
I experimented with a snippet of JavaScript that will display a "Please
Wait" message and graphic while the results of a cgi script is running
(the
script grabs a bunch of data and formats it in a table). Once the page
has
loaded, the script clears the message and graphic. It works fine,
however
if you click the button on the browser to cancel the page load, the
browser
will render what it can of the table and the "Please Wait" message and
graphic is still displayed.
Is there an event that can be acted upon when the user clicks the
browser's
cancel button that would allow me to turn the display of the message
off?
No. Clicking "Cancel" tells the browser to stop doing *anything* in the page and to simply display what it can. Imagine though, if you could trap the Cancel event, and a page author decided to re-call the window.onload handler every time you did, where would you ever get to?
He just wants to hide the status message, not reload the entire
procedure.
John, this should work for you http://www.java2s.com/Code/JavaScrip...StopButton.htm
--
Kailash Nadh | http://kailashnadh.name
Kailash,
Thank you. That worked.
JG
On Nov 28, 2:06 am, "John Gault" <fl...@tattoo-stories.comwrote:
"Kailash Nadh" <kailash.n...@gmail.comwrote in message
news:35**********************************@o6g2000h sd.googlegroups.com...
On Nov 27, 6:04 am, Randy Webb <HikksNotAtH...@aol.comwrote:
John Gault said the following on 11/27/2007 12:05 AM:
I experimented with a snippet of JavaScript that will display a "Please
Wait" message and graphic while the results of a cgi script is running
(the
script grabs a bunch of data and formats it in a table). Once the page
has
loaded, the script clears the message and graphic. It works fine,
however
if you click the button on the browser to cancel the page load, the
browser
will render what it can of the table and the "Please Wait" message and
graphic is still displayed.
Is there an event that can be acted upon when the user clicks the
browser's
cancel button that would allow me to turn the display of the message
off?
No. Clicking "Cancel" tells the browser to stop doing *anything* in the
page and to simply display what it can. Imagine though, if you could
trap the Cancel event, and a page author decided to re-call the
window.onload handler every time you did, where would you ever get to?
He just wants to hide the status message, not reload the entire
procedure.
John, this should work for you http://www.java2s.com/Code/JavaScrip...criptingtheBro...
--
Kailash Nadh |http://kailashnadh.name
Kailash,
Thank you. That worked.
np John. But please keep in mind that the onstop event works only on
IE.
>
JG
--
Kailash Nadh | http://kailashnadh.name
On Nov 27, 8:05 am, "John Gault" <fl...@tattoo-stories.comwrote:
Is there an event that can be acted upon when the user clicks the browser's
cancel button that would allow me to turn the display of the message off?
window.onabort = myEventHandler;
DOM 0, supported since Netscape 2.x
On Nov 28, 3:22 pm, VK <schools_r...@yahoo.comwrote:
On Nov 27, 8:05 am, "John Gault" <fl...@tattoo-stories.comwrote:
Is there an event that can be acted upon when the user clicks the browser's
cancel button that would allow me to turn the display of the message off?
window.onabort = myEventHandler;
Wonderful! Thank you :)
>
DOM 0, supported since Netscape 2.x
--
Kailash Nadh | http://kailashnadh.name This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Phread Barnz |
last post by:
I have an ASP.NET application that I am developing in VS 7.1.3088 (vb code
behind).
The application has 4 pages.
4 buttons and a header control on default.aspx
4 text boxes , 4 buttons, and a...
|
by: deko |
last post by:
I can't move a multi-page report to the last record unless I keep the popup
form (that defined it's subreports) open.
DoCmd.OpenReport "rptStandard", acViewNormal
DoCmd.Close acForm,...
|
by: Rachel Suddeth |
last post by:
I have a tabbed ap, and I want to provide a message and give the user a
chance to change
there mind if they try to change tab pages in the middle of an update
(otherwise just cancel the update and...
|
by: tshad |
last post by:
This is from my previous post, but a different issue.
I have the following Javascript routine that opens a popup page, but doesn't
seem to work if called from an asp.net button. It seems to work...
|
by: David Lozzi |
last post by:
Howdy,
I have a cancel button, I would like to send them to the previous page they
were on. For example, they are viewing a queue of tickets. They can click on
a ticket and update it if they...
|
by: AT |
last post by:
I have an aspx page with this code behind
Public Class WebForm1
Inherits Class1
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
'...
|
by: Benton |
last post by:
Hi there,
I have a UserControl with a couple of textboxes and a couple of buttons
("Save" and "Cancel"). The Click event for this buttons is in the
UserControl's codebehind of course, so here's...
|
by: noneya22 |
last post by:
I'm using asp.net 2.0. I have a page that has a save button and a
cancel button along with a text field. All controls are asp.net
server controls. I have JavaScript that prompts the user if he...
|
by: pankajsingh5k |
last post by:
Dear All,
Please help me...
I had read an article to lazy load a tab in a tabcontainer using an update panel on
http://mattberseth.com/blog/2007/07/how_to_lazyload_tabpanels_with.html
...
|
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...
|
by: ryjfgjl |
last post by:
ExcelToDatabase: batch import excel into database automatically...
|
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...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Defcon1945 |
last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
|
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....
|
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: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |