By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,610 Members | 1,989 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,610 IT Pros & Developers. It's quick & easy.

How do detect "Action Cancelled" page with out polling.

P: n/a
sid
Can someone tell me how to detect "Action Cancelled" page with out
polling.

I have a frame set and I want to make sure the other frame is
displaying what it is supposed to without polling. For some reason
the page does not file OnError or OnLoad events.

Any help is appreciated.

Thanks

Sid.

May 8 '07 #1
Share this Question
Share on Google+
4 Replies


P: n/a
sid wrote:
Can someone tell me how to detect "Action Cancelled" page with out
polling.

I have a frame set and I want to make sure the other frame is
displaying what it is supposed to without polling. For some reason
the page does not file OnError or OnLoad events.
Hi. file = fire?

page A = some page that sometimes fails.
pageB = your page that wants to know if pageA has loaded/displaying right.

If pageA has an onLoad event that mentions it loadedness to page B, you are
fine.
If that, as you claim, does not work, I can think of the following:
- JavaScript is disabled
- You made a codingmistake
- The domain from which pageA and pageB are served are not the same.

you should do something like this from page A:
<body onLoad="parent.frames.frameBnamehere.pageALoaded() ;">

And of course in page B

function pageALoaded(){
alert ("Page B speaking: Page A loaded.");
}

Regards,
Erwin Moller

>
Any help is appreciated.

Thanks

Sid.
May 8 '07 #2

P: n/a
sid
On May 8, 3:09 pm, Erwin Moller
<since_humans_read_this_I_am_spammed_too_m...@spam yourself.comwrote:
sid wrote:
Can someone tell me how to detect "Action Cancelled" page with out
polling.
I have a frame set and I want to make sure the other frame is
displaying what it is supposed to without polling. For some reason
the page does not file OnError or OnLoad events.

Hi. file = fire?

page A = some page that sometimes fails.
pageB = your page that wants to know if pageA has loaded/displaying right.

If pageA has an onLoad event that mentions it loadedness to page B, you are
fine.
If that, as you claim, does not work, I can think of the following:
- JavaScript is disabled
- You made a codingmistake
- The domain from which pageA and pageB are served are not the same.

you should do something like this from page A:
<body onLoad="parent.frames.frameBnamehere.pageALoaded() ;">

And of course in page B

function pageALoaded(){
alert ("Page B speaking: Page A loaded.");

}

Regards,
Erwin Moller


Any help is appreciated.
Thanks
Sid.- Hide quoted text -

- Show quoted text -
Thanks Erwin,

I believe I am narrowing the problem. Yes I can read page B from Page
A as long as the page loads correctly.
But If I receive an "Action Cancelled" or "Page can not be displayed"
I get an "access denied" when I try to read the page contents.

Also, my intention was to set Location.href = "about:Blank" and then
write my own page but I seem to get "access denied" there as well and
both pages are from the same machine.

All this seemed to work correctly when I was testing from the same
machine. (workstation configured with IIS)
But then when I testing that page from a second machine I can't read
the page.

Thanks

Sid.


May 8 '07 #3

P: n/a
sid wrote:
On May 8, 3:09 pm, Erwin Moller
<since_humans_read_this_I_am_spammed_too_m...@spam yourself.comwrote:
>sid wrote:
Can someone tell me how to detect "Action Cancelled" page with out
polling.
I have a frame set and I want to make sure the other frame is
displaying what it is supposed to without polling. For some reason
the page does not file OnError or OnLoad events.

Hi. file = fire?

page A = some page that sometimes fails.
pageB = your page that wants to know if pageA has loaded/displaying
right.

If pageA has an onLoad event that mentions it loadedness to page B, you
are fine.
If that, as you claim, does not work, I can think of the following:
- JavaScript is disabled
- You made a codingmistake
- The domain from which pageA and pageB are served are not the same.

you should do something like this from page A:
<body onLoad="parent.frames.frameBnamehere.pageALoaded() ;">

And of course in page B

function pageALoaded(){
alert ("Page B speaking: Page A loaded.");

}

Regards,
Erwin Moller


Any help is appreciated.
Thanks
Sid.- Hide quoted text -

- Show quoted text -

Thanks Erwin,

I believe I am narrowing the problem. Yes I can read page B from Page
A as long as the page loads correctly.
But If I receive an "Action Cancelled" or "Page can not be displayed"
I get an "access denied" when I try to read the page contents.
Don't try to access pageA from pageB.
Why not?
Excactly as you described: pageA is maybe not loaded or has some error.

Or at least don't try it untill pageA told pageB it has loaded, via the
abovementioned onLoad-event.

>
Also, my intention was to set Location.href = "about:Blank" and then
write my own page but I seem to get "access denied" there as well and
both pages are from the same machine.

All this seemed to work correctly when I was testing from the same
machine. (workstation configured with IIS)
But then when I testing that page from a second machine I can't read
the page.
Yes. That makes sense.
I *think* that about:Blank is considered 'localhost', but I am not 100%
sure.
That means that on your develmachine, you can set it because it is both on
localhost, but once you move to a different machine, pageA and PageB are in
different domain, and then JavaScript security kicks in.

I am not 100% sure that about:Blank is considered 'localhost'.
Maybe somebody else can help you with or you can find a trick to discover
this yourself.

Good luck.

Regards,
Erwin Moller
>
Thanks

Sid.
May 9 '07 #4

P: n/a
sid
On May 9, 7:49 am, Erwin Moller
<since_humans_read_this_I_am_spammed_too_m...@spam yourself.comwrote:
sid wrote:
On May 8, 3:09 pm, Erwin Moller
<since_humans_read_this_I_am_spammed_too_m...@spam yourself.comwrote:
sid wrote:
Can someone tell me how to detect "Action Cancelled" page with out
polling.
I have a frame set and I want to make sure the other frame is
displaying what it is supposed to without polling. For some reason
the page does not file OnError or OnLoad events.
Hi. file = fire?
page A = some page that sometimes fails.
pageB = your page that wants to know if pageA has loaded/displaying
right.
If pageA has an onLoad event that mentions it loadedness to page B, you
are fine.
If that, as you claim, does not work, I can think of the following:
- JavaScript is disabled
- You made a codingmistake
- The domain from which pageA and pageB are served are not the same.
you should do something like this from page A:
<body onLoad="parent.frames.frameBnamehere.pageALoaded() ;">
And of course in page B
function pageALoaded(){
alert ("Page B speaking: Page A loaded.");
}
Regards,
Erwin Moller
Any help is appreciated.
Thanks
Sid.- Hide quoted text -
- Show quoted text -
Thanks Erwin,
I believe I am narrowing the problem. Yes I can read page B from Page
A as long as the page loads correctly.
But If I receive an "Action Cancelled" or "Page can not be displayed"
I get an "access denied" when I try to read the page contents.

Don't try to access pageA from pageB.
Why not?
Excactly as you described: pageA is maybe not loaded or has some error.

Or at least don't try it untill pageA told pageB it has loaded, via the
abovementioned onLoad-event.
Also, my intention was to set Location.href = "about:Blank" and then
write my own page but I seem to get "access denied" there as well and
both pages are from the same machine.
All this seemed to work correctly when I was testing from the same
machine. (workstation configured with IIS)
But then when I testing that page from a second machine I can't read
the page.

Yes. That makes sense.
I *think* that about:Blank is considered 'localhost', but I am not 100%
sure.
That means that on your develmachine, you can set it because it is both on
localhost, but once you move to a different machine, pageA and PageB are in
different domain, and then JavaScript security kicks in.

I am not 100% sure that about:Blank is considered 'localhost'.
Maybe somebody else can help you with or you can find a trick to discover
this yourself.

Good luck.

Regards,
Erwin Moller


Thanks
Sid.- Hide quoted text -

- Show quoted text -- Hide quoted text -

- Show quoted text -
More Progress !

I found an error in the script above all routines that for some reason
blowing up the remote browsers.
Don't know why it worked locally.
The script was call a Sub that I had commented out serveral days ago.
Now works on the second PC

Now I tested it on a brandnew Dell out of the box and now I found that
everytime it set main.location.href = "about:blank" it opened up a new
browser. Why How would I test for that ?

Sid.


May 10 '07 #5

This discussion thread is closed

Replies have been disabled for this discussion.