Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dynimically loaded clips - geting the property - HOW ?

Status
Not open for further replies.

jbezzina

MIS
May 4, 2004
46
MT
I am loading a movie clip (a jpg in this case) into _level20 but I need the _width and _height values.

I am trying the following 2 methods:

in this case I am getting an "undifined" value:


var myMCL:Object = new MovieClipLoader();

for (b=1; b<21; b++) {
this.button.onRelease = function() {
myMCL.loadMovie("gallery/photo10.jpg", 20);
picWidth = myMCL._width;
picHeight = myMCL._height;
trace(picWidth);
trace(picHeight);
};
}
[/color red]

or (in this case I am getting the value of the stage)


var myMCL:Object = new MovieClipLoader();

for (b=1; b<21; b++) {
this.button.onRelease = function() {
myMCL.loadMovie("gallery/photo10", 20);
getProperty = myMCL._width;
getProperty = myMCL._height;
trace(_width);
trace(_height);
};
}
[/color red]

What am I missing ?

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top