# MovieClip size once Jpeg loaded

**URL:** <https://forum.kirupa.com/t/movieclip-size-once-jpeg-loaded/151615>\
**Category:** flash\
**Created:** [June 16, 2005, 8:02pm UTC](https://forum.kirupa.com/t/movieclip-size-once-jpeg-loaded/151615 "2005-06-16T20:02:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![beforedawn](https://avatars.discourse-cdn.com/v4/letter/b/edb3f5/32.png) [@beforedawn](https://forum.kirupa.com/u/beforedawn)\
**Post date:** [June 16, 2005, 8:02pm UTC](https://forum.kirupa.com/t/movieclip-size-once-jpeg-loaded/151615/1 "2005-06-16T20:02:26Z")

</div>

Hi,

I am creating an empty movieclip and loading a jpeg into it. The mc does not seem to resize to account for the jpeg’s size, also the parent mc (thisClip) which is also created dynamically (with attachmovie), is set at 500 - i have no idea why:

thisClip.createEmptyMovieClip(“theJpeg”, 2);  
thisClip.theJpeg.loadMovie(url);  
thisClip.theJpeg.onEnterFrame = function(){  
if(this.getBytesLoaded() \>= this.getBytesTotal())  
{  
delete this.onEnterFrame;  
trace(this.\_width);  
}  
}

any ideas?

thanks in advance

ash
