# MovieClip button

**URL:** https://forum.kirupa.com/t/movieclip-button/273475
**Category:** Uncategorized
**Created:** [October 15, 2008, 10:06pm UTC](https://forum.kirupa.com/t/movieclip-button/273475 "2008-10-15T22:06:52Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![skelebunny](https://avatars.discourse-cdn.com/v4/letter/s/87869e/32.png) [@skelebunny](https://forum.kirupa.com/u/skelebunny)
#### Post date: [October 15, 2008, 10:06pm UTC](https://forum.kirupa.com/t/movieclip-button/273475/1 "2008-10-15T22:06:52Z")

</div>

I want to make a movieclip button that starts and stops the same animation. This is what I have and it obviously doesn’t work. Any ideas?

button\_mc.addEventListener(MouseEvent, CLICK, playAnim);

button\_mc.addEventListener(MouseEvent, CLICK stopAnim);

function playAnim(e:MouseEvent):void

{  
animation\_mc.play();  
}

function stopAnim(e:MouseEvent):void

{  
animation\_mc.stop();  
}

I’m a newby. Thanks.
