# Loading an image through XML, in a MC or loader component, with correct resizeing

**URL:** <https://forum.kirupa.com/t/loading-an-image-through-xml-in-a-mc-or-loader-component-with-correct-resizeing/257230>\
**Category:** flash\
**Created:** [April 11, 2008, 2:19pm UTC](https://forum.kirupa.com/t/loading-an-image-through-xml-in-a-mc-or-loader-component-with-correct-resizeing/257230 "2008-04-11T14:19:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lill](https://avatars.discourse-cdn.com/v4/letter/l/258eb7/32.png) [@Lill](https://forum.kirupa.com/u/Lill)\
**Post date:** [April 11, 2008, 2:19pm UTC](https://forum.kirupa.com/t/loading-an-image-through-xml-in-a-mc-or-loader-component-with-correct-resizeing/257230/1 "2008-04-11T14:19:19Z")

</div>

Hi there im haveing a problem. I’m currently makeing a template in flash with dynamic textboxes and loader component. I get everything to work and all, except, the image goes over the border of the loader component, so it seems the:

my\_ldr.scaleContent = true;

dosn’t work when useing an xml, but works when just picking the image up “direct”  
I have tried this on an empty MC:

```
_root.S2.holder._xscale = 150;
_root.S2.holder._yscale = 150;

```

but then the image thats loaded will not keep its propotions.

Can anyone help?  
Have anyone used the mx.controls.Loader with an XML before? (UIcomponent)
