# Movement Using ActionScript

**URL:** https://forum.kirupa.com/t/movement-using-actionscript/291484
**Category:** Uncategorized
**Created:** [June 30, 2009, 12:30pm UTC](https://forum.kirupa.com/t/movement-using-actionscript/291484 "2009-06-30T12:30:51Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Yve](https://avatars.discourse-cdn.com/v4/letter/y/e9bcb4/32.png) [@Yve](https://forum.kirupa.com/u/Yve)
#### Post date: [June 30, 2009, 12:30pm UTC](https://forum.kirupa.com/t/movement-using-actionscript/291484/1 "2009-06-30T12:30:51Z")

</div>

I’ve done the tutorial that makes the box move across the screen, but i need to know how to make it stop at a certain point on the stage, can anyone tell me the code for this?  
This is the code I have so far:

target1\_mc.onEnterFrame = function() {  
this.\_x += 1;  
}

Many thanks!  
Yve
