MeTV
03-09-2005, 03:09 PM
I'm using the following actionscript to load an external *.swf into an empty movieclip and resize the movieclip accordingly. All goes well except in Firefox where the empty movieclip doesn't resize and, on ocassion, the external *.swf doesn't load at all (I use a javascript alert to let me know whether it's loaded or not).
onClipEvent(load){
newfile=this.loadMovie("/swf/file.swf")
}
onClipEvent(enterFrame){
if(newfile.getBytesLoaded==newfile.getBytesTotal){
this.width=100
this.height=100
_parent.movieclipx._visible=false
delete enterFrame
}
}
<edit> Forgot to say I was on a PC and the only other browser I'd tested it in so far was IE. Since tested it in IE and Safari on a Mac with the same problems. </edit>
onClipEvent(load){
newfile=this.loadMovie("/swf/file.swf")
}
onClipEvent(enterFrame){
if(newfile.getBytesLoaded==newfile.getBytesTotal){
this.width=100
this.height=100
_parent.movieclipx._visible=false
delete enterFrame
}
}
<edit> Forgot to say I was on a PC and the only other browser I'd tested it in so far was IE. Since tested it in IE and Safari on a Mac with the same problems. </edit>