Using code snippets to stop sounds from playing


show more Using code snippets to stop sounds from playing provides you with in-depth training on Web. Taught by Todd Perkins as part of the Flash Professional CS5 Essential Training show less
please wait ...

Using code snippets to stop sounds from playing

Whenever you have music or any kind of sound in an application, it's a good idea to have a mute button. that way the person viewing the application can mute the sound if they want to. So in this application I have a sound that plays during a banner ad. (Music playing) What we will do is we will add functionality to the button on the bottom right of the screen to mute the sound when you click it. To do that, select the button, open the Code Snippets panel, and expand the Audio and Video section.

In there, just double-click Click to Stop All Sounds. Flash tells me the symbol needs an instance name,and since Flash will do that for me, I will just click OK, and there's the code. So I will test the movie in the Flash Player. (Music playing) And then when I click the button, you can see that the sound stops. So to stop all sounds use the Code Snippets panel and use the Click to Stop All Sounds code snippet.

Using code snippets to stop sounds from playing
Video duration: 1m 2s 7h 7m Beginner

Viewers:

Using code snippets to stop sounds from playing provides you with in-depth training on Web. Taught by Todd Perkins as part of the Flash Professional CS5 Essential Training

Subject:
Web
Software:
Flash Professional
Author:
please wait ...