# Movement using buttons and actionscript

**URL:** <https://forum.kirupa.com/t/movement-using-buttons-and-actionscript/30447>\
**Category:** flash\
**Created:** [September 9, 2003, 1:27am UTC](https://forum.kirupa.com/t/movement-using-buttons-and-actionscript/30447 "2003-09-09T01:27:14Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rhombusleech](https://avatars.discourse-cdn.com/v4/letter/r/a6a055/32.png) [@rhombusleech](https://forum.kirupa.com/u/rhombusleech)\
**Post date:** [September 9, 2003, 1:27am UTC](https://forum.kirupa.com/t/movement-using-buttons-and-actionscript/30447/1 "2003-09-09T01:27:14Z")

</div>

I know this is something very simple to do, but I’m just having actionscript writers block. I’ve done searches here for what I’m looking for but haven’t found quite what I want. Here’s what I want to do

I have a movie clip on the stage, say a ball. I also have two buttons, a left and right arrow. When I mouse over the left arrow I want the ball to move left, and vice versa for the right arrow. Also I want to the ball to stop moving when it reaches the edge of the stage, in either direction.

Thanks in advance for the help.
