PDA

View Full Version : [FMX] - Resize load movie?



Gis
January 20th, 2003, 05:52 PM
HI,

How do you resize a swf that is loaded into another movie.

I use:

_root.createEmptyMovieClip("placeholder", 1);
loadMovie("movie.swf", "placeholder");
placeholder._x = 10;
placeholder._y = 50;

What and how do I add the size that the loaded movie should resize to? In this case 200 x 100 pixels

An answer with sample code added to this code would be great!

Thanks,

Gis

pom
January 20th, 2003, 06:39 PM
You have to wait until the movie is fully loaded and then resize the movie just like any clip (because it IS a clip). Search the forum a bit, you should find your answer.

pom :)

senocular
January 20th, 2003, 06:44 PM
heres a quick example:


_root.createEmptyMovieClip("placeholder", 1);
loadMovie("loadme.swf", "placeholder");
_root.createEmptyMovieClip("placeholder_onLoad", 2).onEnterFrame = function(){
if (placeholder.getBytesTotal() && placeholder.getBytesTotal() == placeholder.getBytesLoaded()){
placeholder._x = 10;
placeholder._y = 50;
this.removeMovieClip();
}
}

Gis
January 21st, 2003, 11:20 PM
:-\ I can see this coe checks that the clip is loaded, but how do I set the size after that?

Thanks

Gis