# Need help adding sound to a rollover button

**URL:** <https://forum.kirupa.com/t/need-help-adding-sound-to-a-rollover-button/225939>\
**Category:** flash\
**Created:** [May 16, 2007, 9:30pm UTC](https://forum.kirupa.com/t/need-help-adding-sound-to-a-rollover-button/225939 "2007-05-16T21:30:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![BrianTho](https://avatars.discourse-cdn.com/v4/letter/b/87869e/32.png) [@BrianTho](https://forum.kirupa.com/u/BrianTho)\
**Post date:** [May 16, 2007, 9:30pm UTC](https://forum.kirupa.com/t/need-help-adding-sound-to-a-rollover-button/225939/1 "2007-05-16T21:30:24Z")

</div>

[FONT=Fixedsys][SIZE=5][COLOR=seagreen]Hello,[/COLOR][/SIZE][/FONT]  
[FONT=Fixedsys][SIZE=5][COLOR=#2e8b57]I am trying to add a 1 second WHOOSH! sound to a button rollover for a cool effect. The button is a MC that I have an alpha effect for and I would like to get it to play a sound whenever I rollover it. I was following [this tutorial](http://www.kirupa.com/developer/mx2004/button_effect.htm) from kirupa, but it did not say anything about adding a sound, so i Decided to post this in the forums. I know this is probably something very simple, but I don’t know where to start. Please help. here is my source code…[/COLOR][/SIZE][/FONT]

stop();  
this.onEnterFrame = function(){  
if(rewind == true){  
prevFrame();  
}  
}

this.onRollOver = function(){  
rewind = false;  
play();  
}

this.onRollOut = function(){  
rewind = true;  
}  
this.onRelease = function() {  
\_root.gotoAndStop(“Photos#3\_BIG”);  
}
