ActionScript 3.0 :: Got A Toggle Button That Plays Sound When Clicked?

Jan 3, 2010

So I got a toggle button that plays sound when clicked, now I need it to stop playing sound when clicked again.


View 1 Replies

Similar Posts:

ActionScript 3.0 :: Toggle Button Revisited - Get It To Stop Playing When Clicked On Again

Jan 10, 2010

I redid my toggle button. I have music playing when its clicked down, I just cant get it to stop playing when clicked on again.


View 2 Replies

Javascript :: SWF Video With Controls (toggle Sound On / Off And Toggle Play / Pause)

Jan 10, 2011

I'm new to flash and just need to do a simple task but I can't manage to get it to work. I'm trying to import a video (flv) into a SWF container and need to AS functions which should be exposed to JS (using liveconnect or anything else). These two function should toggle sound on/off and toggle play/pause. I dont need any user interface or a full featured player, just these two functions.

View 1 Replies

ActionScript 3.0 :: Edit Code For Sound Toggle Button

Aug 19, 2010

I need it so the music plays at start and then the button will pause/stop it, and  then turn into a play graphic which, when pressed, will play it again. I tried editing the code, but I am horrible at programming and of course nothing I tried worked. Please let me know what I have to change to start with music playing, and then have it stop/pause on first press, and alternate "play" and "stop" on subsequent presses. 


View 9 Replies

ActionScript 3.0 :: Edit Code For Sound Toggle Button?

Aug 19, 2010

this is the one code that I could make work, but I need it so the music plays at start and then the button will pause/stop it, and then turn into a play graphic which, when pressed, will play it again. I tried editing the code, but I am horrible at programming and of course nothing I tried worked. Please let me know what I have to change to start with music playing, and then have it stop/pause on first press, and alternate "play" and "stop" on subsequent presses.

[My fla has 2 layers, one for this AS, and one for the buttons... within the symbol section, I have two layers, one for the button common BG, and two frames in the button layer, one for play (triangle) and one for stop (square). They are saved as a movie clip.]


View 5 Replies

Professional :: Button Over Sound Plays Again Before Button Down Sound

Apr 15, 2010

I've assigned a sound to the button over frame and a different one to the button down frame. When i over over the button the button over sound plays. When I then click the button, the button over sound plays AND the the sound I put in the button down frame plays.

View 8 Replies

Actionscript 3 :: Flash Play/Pause Sound Toggle Button?

Sep 11, 2010

I've googled and googled but got no where or outdated tutorials. Anyone know how to make it so I can toggle audio with buttons using ActionScript 3 on Flash?

View 2 Replies

ActionScript 2.0 :: Mute Toggle Button To Specific Sound Clip

Jun 3, 2011

Creating the necessary code to make a mute/unmute button in ActionScript 2? I would like the "toggle" button to control a specific sound clip only -- not any other sound within my presentation. Basically I have an intro animation of about 20 seconds that has background music to it. I would like to add a mute toggle button that controls only this music clip and not any other sound found within my presentation. Is this possible? I've seen code for "globally" muting or stopping sounds. I need code for just a specific music clip (sound object?).

View 6 Replies

Button Plays Sound Twice

Nov 28, 2009

In my flash game, every time you click a button, it plays a short sound. Almost all of the buttons work - Except for a few random handful. Those couple play the sound twice. I don't know why either - I double checked everything.None of the frames have sound. The buttons that play twice are only set to play once. I didn't do anything different between the ones that worked and the ones that don't work.

View 2 Replies

ActionScript 3.0 :: Sound Plays When I Click Button

Aug 4, 2010

I have a movie clip with a sound at the beginning of my project, and when I click a button in another scene it starts playing the voiceover from that clip. I don't have the button linked to that clip.

View 2 Replies

ActionScript 3.0 :: Sound Only Plays When Clicking On Pause Button

Sep 2, 2009

All my sounds work however, the play button only seems to play my sound when I click on the pause or stop button first! Plus, my stop button acts like a pause button, it doesn't start the song from the beginning once it stops. [code]...

View 3 Replies

Stop Sound When Next Button Clicked?

Apr 2, 2010

I'm making a page with multiple soundclips - each one launched by a separate Flash button.

Problem: If someone clicks a button and then clicks another button without first stopping or pausing the original soundclip, the two play at the same time. Press another and three clips play at once.

How do I make it so that when you push the next button it stops the first clip and then plays the second one?

View 5 Replies

ActionScript 3.0 :: Button That Play Sound When Clicked And Be Controlled With Events?

Nov 8, 2011

I'm a flash beginner and I've been having alot of trouble figuring out how to make a button which can be controlled with the keyboard as well as the mouse and plays a sound when clicked but when the button is released the sound instantly stops. What I'm going for is a piano application, I made the button, I know how to create keyboard events with listeners and make the different button states up and down but I don't know how to control the button with the keyboard and play sound when the button is clicked but stop the sound when the button is released.

Also I'd like to have it where the space bar will cancel whatever makes the sound stop so it just rings out until the sound clip ends. Can someone explain to me how to do this, remember I'm a beginner so please explain everything.

View 6 Replies

Actionscript 3 :: SoundTransform Is Muting The Sound But Sound Still Plays

Apr 6, 2010

I am using the following code, in the last line when I play the sound I can still hear it even when I have transformed it to 0.


View 1 Replies

ActionScript 3.0 :: Make A Class That Plays An Animation When It Is Clicked On?

Dec 28, 2009

I am trying to accomplish the following:
In my Library, I would like to have a symbol that I can drag to the stage, and when I compile my flash movie and click on the symbol it plays a certain animation. I would prefer for the animation to be defined in the class rather than sit on the timeline.
I have tried various approaches to this and I keep hitting walls, so instead of running down more blind alleys I figured I'd just ask the question... what is the best approach in flash to accomplish this?

View 5 Replies

ActionScript 2.0 :: Toggle Sound On And Off?

Apr 28, 2008

I have a button, just one button, that I want to be able to use to toggle sound on and off. On the button I have included the following actionscript:

on (release) {

Can I add additional script to turn it back on again? Maybe an if statement? The sound is currently being loaded and I cannot really add additional frames to make this work. I have to be able to include the script in one step if possible. Unless a movie with several buttons is the only way to go.

View 1 Replies

ActionScript 3.0 :: External Swfs Load - Remove The Swfs And Sound After A New Button Is Clicked

Nov 13, 2010

I am loading eight external swfs by way of eight buttons with actionscript to remove the swfs and sound after a new button is clicked. This works fine except that as soon as you get to the frame where the actionscript is all the swfs load at one time on top of each other. I don't want any to load until the button is clicked for the right one. MouseEvent listener works but only after all the swfs have loaded. How do I get the swfs to load only when the buttons are clicked. I can't figure out what I am doing wrong.


View 5 Replies

ActionScript 3.0 :: Get Sound Toggle (mute And On)?

Feb 20, 2009

I can get my mc button to mute it once, but never turn on again.The audio is a voice over in streaming in the main timeline.

var soundOn:Boolean = true;
onoff_btn.buttonMode = true;


View 6 Replies

ActionScript 2.0 :: Sound Toggle Using StopAllSounds()?

Apr 3, 2007

I have created a game where all the main actionscript takes place in one frame.For extra functionality I was going to add a button to toggle on/off sounds, after searching this forums and others Im left confused how to implement this.If i choose to use stopAllSounds() Im aware it only stops the current sounds and will not interfere with sounds about to occur.

Collision detection and random sounds occur within my game on an interval, is there a simple way to turn off all sounds permenantly? The only other id would be a button with a toggle and use multiple IF statements to check status of sound on/off.

View 1 Replies

ActionScript 3.0 :: How To Toggle Sound Off/on Of A Music

May 31, 2011

The user should be able to toggle on or off the sounds button where clicking (on) will turn on the sounds while the button's label will be changed to 'off'Initially the sound is off.

View 4 Replies

ActionScript 2.0 :: Sound Toggle On Template File?

Jan 27, 2009

I have a Template file I am editing that plays music in the background. I want to shut it off when a Video is loaded so I added a stopAllSounds to the button. Works fine; however, I cannot figure out how to turn it back on again, as the template designer placed the sound file into a button rather than creating a sound Object. Was hoping someone could help me figure out how to restore sounds (I have tried adding Frame Labels to his sound movie/button but it returns me to the opening on the animation.

I have posted the file here if anyone would like to help. If no time for that, is there a simple way to output what is happening when I hit the toggle button, so I can copy that and try it?

View 1 Replies

ActionScript 3.0 :: Target/pause Mc From Sound Toggle Btn?

Nov 29, 2010

I have a movie clip on the main stage which loops an animation of a gramophone. On a separate mc in the layer above I have a working toggle button which plays and pauses a loaded mp3, but does not yet pause the MC animation beneath it. I need to find a way to target/pause/resume the gramophone MC insync with the sound button which is in another movieclip

View 0 Replies

ActionScript 2.0 :: Sound Toggle Conflict With Music Fade In/out Scripts?

Sep 3, 2007

I have a video and background music in one flash file. I need the background music to fade out when the video is playing, and fade back in when the video is paused. Everything works fine until the Music On/Off button is inserted.If you try out the attached FLA, the background music is able to fade out when the video is played and fade in when the video is paused. But once you toggle the Music On/Off button, the background music fade in/fade out doesn't work anymore.

View 2 Replies

ActionScript 2.0 :: Toggle Any Settings When Importing A Sound Clip Into The Library?

Apr 28, 2008

I embeded an mp3 into a movie clip, and the source mp3 is professional quality, yet the embedded clip sounds horrible.

Is there a way to toggle any settings when importing a sound clip into the library?

View 2 Replies

ActionScript 2.0 :: Active Button - Stay The Rollon Color After It's Clicked And Then The Rolloff Color When Another Button Is Clicked?

Sep 29, 2008

How can I make it stay the rollon color after it's clicked and then the rolloff color when another button is clicked?


View 7 Replies

ActionScript 3.0 :: Detect Wheather The Button Is Clicked Or Not And Disable It If Clicked?

Jun 9, 2010

I have 4 navigation button and like home, about us etc....  And i want to disable home when it is click and cannot clicked it until the user click another button first. means if a visitor is at home page then home navigation is disabled, and all other are active, and when they click at aboutus button then the pages goes to the about us page and the about us button is disabled and other get active. I want this solution in AS3 with oop concept.

View 6 Replies

ActionScript 2.0 :: Buttons To Stay Orange Once Clicked And Only Roll Out Back To Grey When The User Has Clicked On Another Button In The List

Feb 7, 2007

I've got about 6 buttons laid out, one on top of the other in a list format. In their normal state the buttons are grey in colour, when I rollover them, the buttons flash and turn to orange. Now, what I need to happen is this: I want the buttons to stay orange once clicked and only roll out back to grey when the user has clicked on another button in the list. I've been told that the best way to do this is via adding a listener, however I am a little unsure as to how to go about this. I've checked the flash help file and have a basic understanding of how listeners work...but can't really wrap my head around applying it to this situation. Perhaps I will need to have all the buttons as separate broadcasters?

View 2 Replies

Professional :: Site Sound When .FLV Plays

Apr 18, 2011

I have a Flash 8 site that plays a music clip throughout the site.  I have a flv video on one of my site's pages and would like to know if there is a way to stop the site's music when the user clicks on the "Play" button of the video and to have the site music start again when the video either ends or the user clicks on stop.

View 1 Replies

ActionScript 3.0 :: Sound Still Plays When Unloading Swf?

Oct 26, 2009

We have 4 buttons, each calls a different swf. Cannot get one swf to unload audio when another is called.Have tried many scripts but none work. Still hear audio of previous swf on top of newly-loaded swf. This was never a problem in AS2 but too late to go back to AS2, must resolve in AS3.I read that this is a bug but everything I have tried does not work. Have been using UILoader to get position accurate x=150, y=40.

For loading have tried List, UILoader, addChild, etc. Don't know which is best to use so it can be unloaded.

View 4 Replies

ActionScript 2.0 :: Sound Only Plays On Timeline

Nov 20, 2009

sound it only works when placed on timeline. Im pasting the as where im using so that anyone can maybe see a solution. One thing to note, my swf is being loaded by another swf, ok...?


View 1 Replies

Copyrights 2005-15, All rights reserved