Quantcast
Channel: Adobe Community: Message List
Viewing all articles
Browse latest Browse all 92756

Stop a sound from playing

$
0
0

Hi, I am trying to stop a sound from playing when the PlayBtn is pressed. The PlayBtn advances the playhead to the next frame and plays an embedded video.

 

I've tried several different ways of doing this but I am kind of new and self taught.

 

Thanks for any help you can offer.

 

 

 

import flash.utils.getDefinitionByName;   

var SoundClass:Class = getDefinitionByName("YuhYuhEdited") as Class;

var newSound:Sound = new SoundClass();

newSound.play()

 

 

stop();

 

 

PlayBtn.addEventListener(MouseEvent.CLICK, fl_ClickToGoToAndPlayFromFrame_3);

 

function fl_ClickToGoToAndPlayFromFrame_3(event:MouseEvent):void

{

  gotoAndPlay(2);

}


Viewing all articles
Browse latest Browse all 92756

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>