# Dynamically cropping (masking) an image

**URL:** <https://forum.kirupa.com/t/dynamically-cropping-masking-an-image/295049>\
**Category:** flash\
**Created:** [August 24, 2009, 7:02pm UTC](https://forum.kirupa.com/t/dynamically-cropping-masking-an-image/295049 "2009-08-24T19:02:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![morty66](https://avatars.discourse-cdn.com/v4/letter/m/49beb7/32.png) [@morty66](https://forum.kirupa.com/u/morty66)\
**Post date:** [August 24, 2009, 7:02pm UTC](https://forum.kirupa.com/t/dynamically-cropping-masking-an-image/295049/1 "2009-08-24T19:02:45Z")

</div>

Hi, I made an xml loaded dynamic image gallery and I cannot figure out how to crop the image should it be too big.  
Masking appears to work only with a movieclip created outside of actionscript (which cannot be created dynamically).

Thanks in advance.
