Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

window.opener error

Status
Not open for further replies.

janise

Technical User
May 25, 2003
161
US
Hello gurus!
I am trying to atleast understand why I am having the error that I am having so I can beging to isolate the problems.
The error says:

window.opener.top is null or is not an object.
Can someone please tell me what this means?
 
This could mean that there is no window.opener (meaning the code exists on a page that wasn't opened by code on a previous page)

OR

it could mean that the window.opener is the top node and has no "top" (meaning that is isn't part of a framset)

Programming today is a race between software engineers striving to build better and bigger idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. - Rick Cook (No, I'm not Rick)

fart.gif
 
thank you mwolf00 for the response.
On one page, I have this snip:

function getNumber() {
found = false;
proj_num = document.control_form.proj_num_input.value.toUpperCase();
for ( i=0; i < document.control_form.length; i++ ) {
if (document.control_form.elements.name == proj_num) {
found = true;
}
}
if (found == true) {
extent = eval(&quot;document.control_form.&quot;+proj_num+&quot;.value&quot;);
zoomToExtent(extent);
}
else {
alert(&quot;No such project.&quot;);
}
}

On another, I have this:

function zoomToExtent(extent, token) {


setLayers(window.opener.top);
opener.top.body_frame.left_frame.document.mapserv.target = &quot;left_frame&quot;;
opener.top.body_frame.left_frame.document.mapserv.mapext.value = extent;
//opener.top.body_frame.left_frame.document.mapserv.map_sstreet_class_expression.value = &quot;'&quot;+token+&quot;'&quot;;
setTemplate(&quot;map.html&quot;,window.opener.top);
setMapSize(window.opener.top);
opener.top.body_frame.left_frame.document.mapserv.submit();
//top.body_frame.left_frame.document.mapserv.mapext.value = basin_extent;


self.close();

}


When I run the first page, I get the error I posted above pointing to:
setLayers(window.opener.top);

Could it be that I am getting this error because
function zoomToExtent(extent, token)has two parameters while the calling page this --> zoomToExtent(extent) has one?

Please assist
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top