# Auto resize images

**URL:** https://forum.kirupa.com/t/auto-resize-images/267800
**Category:** flash
**Created:** [August 5, 2008, 8:52pm UTC](https://forum.kirupa.com/t/auto-resize-images/267800 "2008-08-05T20:52:44Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![jcafaro10](https://avatars.discourse-cdn.com/v4/letter/j/a183cd/32.png) [@jcafaro10](https://forum.kirupa.com/u/jcafaro10)
#### Post date: [August 5, 2008, 8:52pm UTC](https://forum.kirupa.com/t/auto-resize-images/267800/1 "2008-08-05T20:52:44Z")

</div>

I’m creating a dynamic photo gallery. All of the images are in a folder which I access via an xml file to get the pictures to show up when I click them. This makes things alot more convenient. However, the pictures come in varying sizes and because I use the same mask/stage to display all of the pictures I need them to be all similar dimensions. I don’t want to just mass resize all of them b/c they aren’t the same proportions. Is there a way to get flash to make the picture be a certain size but keep its proportions

To get the picture to show up on stage I have a movieclip and I use the following code:

```auto
picture.loadMovie(image[p], 1);//attach actual picture to first level of movieclip

```

picture is the name of the movieclip and image is an array of pictures
