Sizing a Loaded Movie
- Started
- Last post
- 5 Responses
- autonoma
I'm loading a swf using loadMovie. How do I go about making sure the clip that's loaded conforms to the size of the clip it's being loaded into?
Each clip that I'm loading is of a different size, but I want it to load into a clip that's approximately 500x400 and I want it to shrink to that size.
- unfittoprint0
//load check
checkLoad=function(targetMC, targetWidth, targetHeight){
if(targetMC.getBytesLoaded == targetMc.getBytesTotal() && targetMC.getbytesTotal()>4){
clearinterval(checkLooo)
targetMC._width = targetWidth;
targetMC._height=targetheight;
}
}//start
myMC.loadMovie("movie.swf");checkLoop = setInterval(this, "checkLoad", 30, myMC, 500, 400)
- autonoma0
Thanks a million, unfit. I'll give it a shot.
- autonoma0
Hmm. Doesn't work right. I was actually doing something very similar before. When the preload script completed I'd have it try to dynamically resize the loaded clip and it doesn't work.
- ozhanlion0
make sure it has loaded.
- autonoma0
I did.