MACROMEDIA FLASH MX 2004-ACTIONSCRIPT LANGUAGE Reference page 749

Actionscript language reference
Table of Contents

Advertisement

Event handler summary for the Sound class
Event handler
Sound.onID3
Sound.onLoad
Sound.onSoundComplete
Constructor for the Sound class
Availability
Flash Player 5.
Usage
new Sound([target:Object]) : Sound
Parameters
The movie clip instance on which the Sound object operates. This parameter
target
is optional.
Returns
A reference to a Sound object.
Description
Constructor; creates a new Sound object for a specified movie clip. If you do not specify a target
instance, the Sound object controls all of the sounds in the movie.
Example
The following example creates a new Sound object called
and adjusts the volume on all sounds in the movie to 50%.
setVolume()
var global_sound:Sound = new Sound();
global_sound.setVolume(50);
The following example creates a new Sound object, passes it the target movie clip
the
method, which starts any sound in
start
var movie_sound:Sound = new Sound(my_mc);
movie_sound.start();
Description
Invoked each time new ID3 data is available.
Invoked when a sound loads.
Invoked when a sound stops playing.
my_mc
. The second line calls
global_sound
.
, and calls
my_mc
Sound class
749

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH MX 2004-ACTIONSCRIPT LANGUAGE and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Flash mx

Table of Contents