There is a complete event that fires when the swf is loaded. The updateComplete after that is the one you want. You'll get updateCompletes at other times as well
________________________________ From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Mark Ingram Sent: Wednesday, May 30, 2007 9:03 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Image - contentHeight / contentWidth Hi, I'm trying to work out the aspect ratio of an image for a drag resize that I will be doing. I read the docs (http://livedocs.adobe.com/flex/201/langref/mx/controls/SWFLoader.html#c ontentHeight <http://livedocs.adobe.com/flex/201/langref/mx/controls/SWFLoader.html#c ontentHeight> ) and it says: "The value of this property is not final when the complete event is triggered. You can get the value after the updateComplete event is triggered." So, I registered for the FlexEvent.UPDATE_COMPLETE event, and when it fired, I got the contentHeight and contentWidth - but they were both 0! (Looks like the image still hadn't downloaded). Now I get the aspect ratio on the mouse down event, but I don't like calculating the ratio every time the user clicks! I would prefer to get it one time only. Any clues on this much appreciated, Mark