# Sound on / off Flash MX

**URL:** https://forum.kirupa.com/t/sound-on-off-flash-mx/25770
**Category:** flash
**Created:** [July 16, 2003, 11:45am UTC](https://forum.kirupa.com/t/sound-on-off-flash-mx/25770 "2003-07-16T11:45:27Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![sagit](https://avatars.discourse-cdn.com/v4/letter/s/839c29/32.png) [@sagit](https://forum.kirupa.com/u/sagit)
#### Post date: [July 16, 2003, 11:45am UTC](https://forum.kirupa.com/t/sound-on-off-flash-mx/25770/1 "2003-07-16T11:45:27Z")

</div>

Hi guys:  
I’d like to produce a similar on/off button with the orange sound waves like in this site [http://www.donshaw.com/](http://www.donshaw.com/). I love it, can I put the sound to loop in the first frame as an object sound, I have a 1 mins loop sound to go with it, how do I accomplish all of this?  
Thanks a lot guys, I will post my website this week since it is ready to launch I just need to work with sound thing.

Jorge

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [July 16, 2003, 2:16pm UTC](https://forum.kirupa.com/t/sound-on-off-flash-mx/25770/2 "2003-07-16T14:16:47Z")

</div>

Ive done something similar.  
What i did was have a animation in my main movie (the sound waves) with an on and off button. Now i load the sound via a external movieclip and when the sound is loaded i tell it to go to and play the animation of the sound waves in the main movie.

I had an fla, i lost it though!!

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [July 16, 2003, 2:44pm UTC](https://forum.kirupa.com/t/sound-on-off-flash-mx/25770/3 "2003-07-16T14:44:53Z")

</div>

well as far as the equalizer, do a search.  
to attach sound

import your sound into your library, right click and go to linkage

give it the a name of bgSound. check off hte first and last checkboxes.

go to a blank frame in your timeline

[AS]  
mySound = new Sound();  
mySound.attachSound(“bgSound”);  
mySound.start(0,999); // loop 999 times  
[/AS]

crate 2 buttons, on / off

on actions  
[AS]  
on(release){  
if(playing != true){  
mySound.start(0,999);  
playing = true;  
}  
}  
[/AS]

off actions  
[AS]  
mySound.stop();  
[/AS]
