How do i put music on my flash layout...?

hi i am doing a web site layout in flash mx and i want to put a thing where u can play music in the bg, when u load the flash file it automaticly starts and u can choose to turn it of or on by clicking on some text…does anyone know how to fo this? if so please reply!

yep, give the zipped fla and sound

cant u tell me how to do it here?

ello,

well there are two ways you can do what you want:

  1. Easier but less control : Make a movieClip and drop the soundfile in the first frame of the movieClip (or use the properties panel for the first frame). Add a stop action (stop():wink: to the first frame. Then make a keyframe (in the second frame). Add a stopAllSounds (stopAllSounds():wink: action to this second frame. After that add a stop action to the second frame. So now you have one frame with a sound file playing and a second frame with a stopAllSounds action (which of course stops the sound from playing… but also stops all other playing sounds). Now drag and drop the movieClip onto the main Scene. Name the movieClip something (like “music” or something). You do this using the properties panel. The sound should start playing as soon as the movie hits the frame in which you put the movieClip (judging by what you said, this should be frame 1).
    You can stop the music by just making a button (outside of the movieClip) and adding the following code to it :

on (release){

_root.name_of_Movie_Clip.gotoAndPlay(2);

}

To play the music again you can duplicate the button and change the code to read:


on (release){

_root.name_of_Movie_Clip.gotoAndPlay(1);

}

Well there’s the easy way. Now you cant control volume, or panning or pausing etc. The “harder” method lets you do this. Please reply if you need volume and stuff too… Cause I dont wanna explain the whole thing here if not needed.:beam:

Hope I helped.

-Aditya

im gettin confused here…:S cud u make a .fla file for me and i just edit it…or… u cud tell me in an easyer way i am a beginner at flash but i know some of the basics…i have a pic of text that says On and i selected it and gone to libary and dragged the sound file over to that now what do i do?

oki I will make a fla… give me two min…

-Aditya
sorry I confused you =D

ok…thanks :beam: but how ill u send it me?

Oki… me all done :thumb:

Some of my instructions or tips are in the actions panel so keep that open…

Fla : http://simvision.sytes.net/Random/button_play_stop_music.fla

well hope thats what u need

-Aditya

thanks dude u rule:bounce: do u have msn messenger

ive put it into my .fla layout and when i change it to my music it doesnt play in the preview but only when i change it to “start” but when i click the button it doesnt stop what shall i do?its current;y on "stream"but it doesnt play

why dont you IM me…

my messenger is adityagaddam@hotmail.com

-Aditya
I didn’t get that last post… of your…confusing… :cyclops: