# Changing the width of a picture by sliding a button

**URL:** <https://forum.kirupa.com/t/changing-the-width-of-a-picture-by-sliding-a-button/177798>\
**Category:** flash\
**Created:** [February 5, 2006, 10:30am UTC](https://forum.kirupa.com/t/changing-the-width-of-a-picture-by-sliding-a-button/177798 "2006-02-05T10:30:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jnshey](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/jnshey/32/2125_2.png) [@jnshey](https://forum.kirupa.com/u/jnshey)\
**Post date:** [February 5, 2006, 10:30am UTC](https://forum.kirupa.com/t/changing-the-width-of-a-picture-by-sliding-a-button/177798/1 "2006-02-05T10:30:39Z")

</div>

How can I create a button to control the width of a certain picture by just sliding the button on a scale in Flash 8? (I’ve found the actionscript for the button in a sample file in Flash MX. It looks like this:  
[COLOR=navy]onClipEvent (load) {  
initx = \_x;  
left = \_x-50;  
right = \_x+50;  
top = \_y;  
bottom = \_y;  
}[/COLOR]
