# Mouse button Help

**URL:** https://forum.kirupa.com/t/mouse-button-help/187107
**Category:** flash
**Created:** [April 26, 2006, 6:27pm UTC](https://forum.kirupa.com/t/mouse-button-help/187107 "2006-04-26T18:27:55Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Edurs2000](https://avatars.discourse-cdn.com/v4/letter/e/f4b2a3/32.png) [@Edurs2000](https://forum.kirupa.com/u/Edurs2000)
#### Post date: [April 26, 2006, 6:27pm UTC](https://forum.kirupa.com/t/mouse-button-help/187107/1 "2006-04-26T18:27:55Z")

</div>

Hi,

Can I make a mouse button work like nextframe and previusframe.  
I need mouse function like mouseup or mouse release button.

left mouse button --\> nextframe  
right mouse button --\> previusframe  
Flash buttons must work at same time

I have this code, but is to fast.

var flag:Boolean=true;

stop();  
this.onEnterFrame = function(){  
if(flag){  
if (Key.isDown(1)){  
nextFrame();  
}  
if (Key.isDown(2)){  
prevFrame();  
}  
}  
}

thanks any help

Ed
