views:

25

answers:

2

I'm constructing a book of sorts in Actionscript 3 (FlexBuilder) and am trying to size an image dynamically according to the dimensions of it's source file. But, I've found that if I don't explicitly state the width and height of an image, they trace as 0.

So that I can scale down an image to fit within a given space, how do I get the width and height of a source image?

A: 

Do these help?

Gabriel McAdams
The two answers are pretty close, and the second example here looks like it might be what I need. I have to load the image, then run the numbers with scaling for width and height, then set the image to the best fit for the available space.
Charles Shoults
A: 

A flash.display.Loader has width and height attributes.

Will