as3 sound on off ボタン

これだー。
助かった。
http://www.flepstudio.org/forum/actionscript-3-0-newbies/1587-button-turn-off-sound.html
Riferimento: Button Turn On/Off Sound

                                              • -

var music:Sound = new Sound(new URLRequest("music.mp3"));
var trans:SoundTransform = new SoundTransform(1, -1);
var channel:SoundChannel = music.play(0, 1, trans);
var musicOn:Boolean = true
onBtn.addEventListener(MouseEvent.CLICK, onSound);
offBtn.addEventListener(MouseEvent.CLICK, offSound);
function offSound(e:Event) {
musicOn = false;
trans.volume=0;
SoundMixer.soundTransform = trans;
}
function onSound(e:Event) {
musicOn = true;
trans.volume=1;
SoundMixer.soundTransform = trans;
}

In this case the name of the buttno are:
Button ON: onBtn
Button OFF:offBtn

                              • -
                            • -

参考