# Loaded dimensions problems!

**URL:** <https://forum.kirupa.com/t/loaded-dimensions-problems/40838>\
**Category:** Uncategorized\
**Created:** [January 22, 2004, 3:02pm UTC](https://forum.kirupa.com/t/loaded-dimensions-problems/40838 "2004-01-22T15:02:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jerry](https://avatars.discourse-cdn.com/v4/letter/j/5daacb/32.png) [@jerry](https://forum.kirupa.com/u/jerry)\
**Post date:** [January 22, 2004, 3:02pm UTC](https://forum.kirupa.com/t/loaded-dimensions-problems/40838/1 "2004-01-22T15:02:43Z")

</div>

Hey there!  
I really need some help on this one. I’m trying to make a loaded .jpg dragable within a mask (see attached .fla)…

My code works fine when the image already is on the stage (inside a MC), but when I try to load the .jpg into a movieclip, it F…'s things up - and I can’t see whats worng!?

here’s my AS for the loading:

```auto
_root.image.loadMovie("01.jpg");
_root.onEnterFrame = function() {
l=this.image.getBytesLoaded();
t=this.image.getBytesTotal(); 
countdisplay = math.round((l/t)*100);
if (l > 1 && l >= t) {
delete this.onEnterFrame;
if (l >= 100) {

  _root.image.onPress = function(){
	startDrag(this, false ,_root.maskBox._x-((this._width-_root.maskBox._width)/2), _root.maskBox._y-((this._height-_root.maskBox._height)/2), _root.maskBox._x+((this._width-_root.maskBox._width)/2), _root.maskBox._y+((this._height-_root.maskBox._height)/2));
	}
	
_root.image.onRelease = function(){
	stopDrag();
	}
	
_root.image.onReleaseOutside = function(){
	stopDrag();
	}
  
  } 

}
}

```
