4

Can someone please help quickly mute or unmute the stage volume in Flash CS3 using AS 3.0.

Thanks

Anriëtte Myburgh
  • 13,347
  • 11
  • 51
  • 72
  • Have a look [here](http://schoolofflash.com/2008/03/tutorial-using-sound-in-actionscript-3/). There are a lot out there I guess. – George Profenza Sep 01 '09 at 13:22

2 Answers2

13

What you want is the SoundMixer class. Just set it's soundTransform object like this:

Mute:

SoundMixer.soundTransform = new SoundTransform(0);

Unmute:

SoundMixer.soundTransform = new SoundTransform(1);
Branden Hall
  • 4,468
  • 18
  • 19
2

Put this line into your script when you want to stop the sound:

SoundMixer.stopAll();
Bo Persson
  • 90,663
  • 31
  • 146
  • 203