.js file not completing ?

G

Guest

function resetall() {
alert("reset");
parent.totalcostcell.document.getElementById('theTotal').innerHTML = "";
parent.showorderpageiframe.reload();
alert("end of reset");
}


this function is called from another page ok, but the 'reload' and 'end of
reset' lines do not execute.
if i comment out the 'reload' line then the script works ok.

something must be wrong with parent.showorderpageiframe.reload();

what could be wrong with this line.

thanks

Jason
 
S

Steve Easton

What is "reload" at the end of parent.showorderpageiframe.reload(); ??

Is it a function you have created somewhere??


--
Steve Easton
Microsoft MVP FrontPage
95isalive
This site is best viewed..................
...............................with a computer
 
J

Jon Spivey

Hi,
it should be
parent.showorderpageiframe.location.reload();

Javascript is written as object.method() or object.property however the
window object is always assumed - eg technically to get a message box we'd
use window.alert('message') as alert is a method of the window object.
However when no object is stated the window object is assumed - so we can
just write alert('message'). This won't work with any other object though -
as reload() is a method of the location object we need to specify the
location object - location.reload()
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top