I am calling ‘checkForProgressBar’ from a forms onsubmit. The below JS fails. But if I uncomment the ‘showProgressBar’ and comment out the setTimeout(… in checkForProgressBar the script works. I read somewhere that when using setTimeout that ‘this’ gets screwed up (something to do with scope). Is this the case here?
Any help appreciated!! Thanks
function checkForProgressBar() {
if (document.form1.fileName.value != “”) {
//showProgressBar();
setTimeout(‘showProgressBar()’,500);
};
};
function showProgressBar() {
myLightWindow.activateWindow({
href: ‘
title: ”,
width: 360, // must match the iframe in progBarFrame.asp
height: 60 // must match the iframe in progBarFrame.asp
});
};