[Javascript] JavaScript error: Class doesn't support Automation
walterash
walter at harder.net
Thu Sep 12 15:37:17 CDT 2002
Each time I open a window without a URL specified and then try to do
anything (like write to it), IE 6 gives me this error. I tried
reverting to the IE version that came with XP and the problem did
not go away. Can this really be a problem with IE6 and Javascript
or is there something I can fix with my version of IE.
Here's some code from another site (I'm sure webshots.com won't mind
if I borrow it for demonstration purposes) that behaves the same way
(just so you know it's not an error in my code):
-----------
function openwin(name,w,h,scrollbars,resizable,url)
{
var left = (screen.width-w)/2;
var top = (screen.height-h)/2;
var win = window.open("",name,"width=" + w + ",height=" + h
+",scrollbars=" + scrollbars +",resizable=" + resizable
+",screenx="+left+",screeny="+top+",left="+left+",top="+top);
if (url)
win.location.href=url;
win.focus();
}
function onClickPoster()
{
document.location.href = "http://www.webshots.com/g/32/596-
sh/17275.html?blockPop=1";
openwin("poster", 640,
430, "yes", "yes", "http://www.webshots.com/g/poster/75/17275_poster.
html");
}
-------------
When onClickPoster is called, IE6 opens "About:Blank" and give the
error message.
Thank you for any assistance.
Walter Harder
More information about the Javascript
mailing list