# Resizing A Movieclip With as 2.0

**URL:** <https://forum.kirupa.com/t/resizing-a-movieclip-with-as-2-0/306772>\
**Category:** flash\
**Created:** [March 22, 2010, 9:11am UTC](https://forum.kirupa.com/t/resizing-a-movieclip-with-as-2-0/306772 "2010-03-22T09:11:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![h\_waheed](https://avatars.discourse-cdn.com/v4/letter/h/cdc98d/32.png) [@h\_waheed](https://forum.kirupa.com/u/h_waheed)\
**Post date:** [March 22, 2010, 9:11am UTC](https://forum.kirupa.com/t/resizing-a-movieclip-with-as-2-0/306772/1 "2010-03-22T09:11:37Z")

</div>

i’m new to action script 2.0 and i want to create a movie clip dynamically whose position and dimensions are changed in each frame as loaded from xml;

function checkVar(row\_,col\_,xx\_,yy\_)  
{  
var col =col\_;  
var row = row\_;  
var xx = xx\_;  
var yy = yy\_;  
myButton1._x = row_;  
myButton1._y = col_;  
myButton1.buttonBkg.beginFill(0x000000,10);  
myButton1.buttonBkg.lineTo(yy, 0);  
myButton1.buttonBkg.lineTo(yy, xx);  
myButton1.buttonBkg.lineTo(0, xx);  
myButton1.buttonBkg.lineTo(0, 0);  
}  
the position and dimension are changed but the problem is the last dimensions are not removed and it get bigger n bigger
