Sound on/off button
I am creating an elearning movie with many scenes. for each a
scene an external sound clip loads. i would like to create a sound
on/off button. I can create the button and turn the sound off. But
the problem i have is that it only turns it off for that particular
scene. So when the user goes to the next scene. the sound will come
back on because it loads an external sound clip. Is there any way
that the user can switch the sound on/off and it effects the all
the scenes?
Thanks
Don't use scenes. Ever. Big no no. Scenes are what was left
over from Flash 4 before Movie Clips were invented. Code from one
scene cannot communicate with code in another, and there are many
more problems. Divide your main timeline into sections with frame
labels, and use that to separate parts of your application.
Similar Messages
-
The volume On/Off switch does not work. It does not mute sound. I have to turn volume all the way down to silence the sound.
Is the switch faulty or am I missing something here?well first remove the case. check the headphone jack for debris. do a hard reset by holding sleep/wake and home button down together for 10 seconds untill apple appears. backup and restore via itunes. if issue persists the device needs repair
-
Flash MX - Sound on/off button not working properly.
I used the tutorial found here. The 3 frames of my button are in a movie clip, within a keyframe in the main timeline. I used the code at the end in the tutorial for the first keyframe, so that the clip begins with music playing. However; I cannot get the buttons to work. I cannot stop the sound. Help please? I desperately need it.
show the code you used.
-
How to create a Flash Sound On/Off Button
I created a flash intro with background music, I want to be
able to turn the sound off and on. I tried the tutorial (
http://www.entheosweb.com/Flash/flash_sound_button.asp).
This is the error I get.
Target not found: Target="../sound" Base="_level0.music"
Any tips would be a great help.search google for a tutorial on using the sound class. that
tutorial you referenced is antiquated. -
New at Flash, please help! Sound On/Off Button
I'm trying to create a button that when clicked once, it plays music, and when clicked again, it stops. I don't need the button image to change at all, I just need a simple start/stop.
I've been able to make the button start the music when clicked but I've not been successful in making it stop.
I am using CS4, and have no scripting experience.
This is for a graphic arts assignment so please help!drag your button to the stage and assign it an instance name (eg, btn). you can then use:
var sound:MP3=new MP3();
var sc:SoundChannel = sound.play();
btn.addEventListener(MouseEvent.CLICK,f);
function f(e:MouseEvent):void{
if(sc){
sc.stop();
sc=null;
} else {
sc=sound.play(); -
Adding On/Off Button for Sound
Hi,
I have added a music sound to my website, how can I creat an
Sound On/Off button for users to control?
Thank you!Never mind, found it!
http://www.partnersinrhyme.com/contact/tutorials.php?sub=Flash&cat=Adding%20Audio%20to%20P rojects&sno=62
Sorry for the inconvenience. -
Global 'Sound on/off' option?
Hi;
Is there a way of making a global 'sound on/off' button that will work across the entire set of articles in an app? or do you have to have a button on each article, that controls just that one article?
thankyouHi;
Is there a way of making a global 'sound on/off' button that will work across the entire set of articles in an app? or do you have to have a button on each article, that controls just that one article?
thankyou -
Sound on/off by click a button in flex4????
hello everybody, i want to make a website by flex.in that have sound effect. i want when i load page have sound and if i don't want to listen i can click button.the sound will stop play and else. But i don't know how to make on/off sound by a button click
i done:
in actionscript file Sound_playExample1.as: i write code
package myComponents {
import flash.display.Graphics;
import flash.display.Sprite;
import flash.events.Event;
import flash.events.MouseEvent;
import flash.events.ProgressEvent;
import flash.media.Sound;
import flash.media.SoundChannel;
import flash.net.URLRequest;
public class Sound_playExample1 extends Sprite {
private var snd:Sound = new Sound();
private var channel:SoundChannel = new SoundChannel();
public function Sound_playExample1() {
var req:URLRequest = new URLRequest("myComponents/soundall.mp3");
snd.load(req);
channel = snd.play(0,6);
// ActionScript file
in my Main.mxml:i write
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:MyComp="myComponents.*"
xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600">
<fx:Script>
<![CDATA[
protected function button1_clickHandler(event:MouseEvent):void
// TODO Auto-generated method stub
]]>
</fx:Script>
<fx:Declarations>
<MyComp:Sound_playExample1/>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>
<s:Button x="177" y="71" label="Button" click="button1_clickHandler(event)"/>
</s:Application>
can u help me please what i have to do. if you know you can
Additional for this code.thanks// below code sinppet should go into on button click event handle method.
if
(pausePosition==0 ){ if(channel!=null){pausePosition = channel.position;
channel.stop();
sound.setStyle("icon",soundOffClass); // mute
}else{
if(channel!=null){channel.stop();
channel = snd.play(pausePosition);
sound.setStyle("icon",soundOnClass); // un mute , this should be default as
pausePosition=0; -
On/off sound by a button in flex
hello everybody, i want to make a website by flex.in that have sound effect. i want when i load page have sound and if i don't want to listen i can click button.the sound will stop play and else. But i don't know how to make on/off sound by a button click
i done:
in actionscript file Sound_playExample1.as: i write code
package myComponents {
import flash.display.Graphics;
import flash.display.Sprite;
import flash.events.Event;
import flash.events.MouseEvent;
import flash.events.ProgressEvent;
import flash.media.Sound;
import flash.media.SoundChannel;
import flash.net.URLRequest;
public class Sound_playExample1 extends Sprite {
private var snd:Sound = new Sound();
private var channel:SoundChannel = new SoundChannel();
public function Sound_playExample1() {
var req:URLRequest = new URLRequest("myComponents/soundall.mp3");
snd.load(req);
channel = snd.play(0,6);
// ActionScript file
in my Main.mxml:i write
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:MyComp="myComponents.*"
xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600">
<fx:Script>
<![CDATA[
protected function button1_clickHandler(event:MouseEvent):void
// TODO Auto-generated method stub
]]>
</fx:Script>
<fx:Declarations>
<MyComp:Sound_playExample1/>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>
<s:Button x="177" y="71" label="Button" click="button1_clickHandler(event)"/>
</s:Application>
can u help me please what i have to do. if you know you can Additional for this code.thanksHi,
This is complete solution of your issue.Let me know if u find and issue.
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/halo"
creationComplete="application1_creationCompleteHandler(event)"
>
<fx:Script>
<![CDATA[
import mx.events.FlexEvent;
private function onClick():void
createSound();
channel = sound.play();
private function offClick():void
if(channel != null)
channel.stop();
private var sound:Sound;
private var channel:SoundChannel = new SoundChannel();
protected function application1_creationCompleteHandler(event:FlexEvent):void
isPlaying = false;
onOff();
private function createSound() : void
var req:URLRequest = new URLRequest("assets/audio1.mp3");
if(channel != null)
channel.stop();
if(sound != null)
sound = null;
sound = new Sound();
sound.load(req);
[Bindable]
private var isPlaying : Boolean;
protected function onOff():void
if(isPlaying == false)
onClick();
isPlaying = true;
return;
else
offClick();
isPlaying = false;
]]>
</fx:Script>
<s:HGroup>
<s:Button label="{isPlaying == false? 'ON' : 'OFF'}" click="onOff()"/>
</s:HGroup>
</s:Application>
with Regards,
Shardul Singh Bartwal -
On/off sound in a button in flex4
hello everybody, i want to make a website by flex.in that have sound effect. i want when i load page have sound and if i don't want to listen i can click button.the sound will stop play and else. But i don't know how to make on/off sound by a button click
i done:
in actionscript file Sound_playExample1.as: i write code
package myComponents {
import flash.display.Graphics;
import flash.display.Sprite;
import flash.events.Event;
import flash.events.MouseEvent;
import flash.events.ProgressEvent;
import flash.media.Sound;
import flash.media.SoundChannel;
import flash.net.URLRequest;
public class Sound_playExample1 extends Sprite {
private var snd:Sound = new Sound();
private var channel:SoundChannel = new SoundChannel();
public function Sound_playExample1() {
var req:URLRequest = new URLRequest("myComponents/soundall.mp3");
snd.load(req);
channel = snd.play(0,6);
// ActionScript file
in my Main.mxml:i write
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:MyComp="myComponents.*"
xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600">
<fx:Script>
<![CDATA[
protected function button1_clickHandler(event:MouseEvent):void
// TODO Auto-generated method stub
]]>
</fx:Script>
<fx:Declarations>
<MyComp:Sound_playExample1/>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>
<s:Button x="177" y="71" label="Button" click="button1_clickHandler(event)"/>
</s:Application>
can u help me please what i have to do. if you know you can
Additional for this code.thanks// below code sinppet should go into on button click event handle method.
if
(pausePosition==0 ){ if(channel!=null){pausePosition = channel.position;
channel.stop();
sound.setStyle("icon",soundOffClass); // mute
}else{
if(channel!=null){channel.stop();
channel = snd.play(pausePosition);
sound.setStyle("icon",soundOnClass); // un mute , this should be default as
pausePosition=0; -
No Sound. Speaker "on" "off" button not functioning
I have an HP Pavillion Laptop which was purchased in the last 9 months. Don't know what kind of sound board is installed. Running Windows 8. Upgraded to Windows 8.1 last week and now I don't have any sound. When I press the Speaker "On/Off" button nothing happens; it doesn't even light. Can anyone tell me what happened and how to fix?
Hi Nana-Carol. It is most likely a driver issue, since it started after the upgrade to Windows 8.1. It is possible that HP has drivers for Windows 8.1. What is the model number of your notebook?
<How Do I Find My Notebook Model Number>: http://h10025.www1.hp.com/ewfrf/wc/document?lc=en&cc=us&docname=c00033108
TwoPointOh
I work on behalf of HP
Please click “Accept as Solution ” if you feel my post solved your issue, it will help others find the solution.
Click the “Kudos, Thumbs Up" on the bottom to say “Thanks” for helping! -
I like to listen to lectures, etc. and find it very annoying to have to press the on/off button to restart it every 10 minutes. Couldn't find a way to extend playing time in settings. Any suggestions? This is my first iPod and I am ready to take it back if I am unable to extend the playing time. Frustrating!
Rosapeas wrote:
I like to listen to lectures, etc. and find it very annoying to have to press the on/off button to restart it every 10 minutes. Couldn't find a way to extend playing time in settings. Any suggestions? This is my first iPod and I am ready to take it back if I am unable to extend the playing time. Frustrating!
I can imagine that is frustrating as heck. My daughter has one of these and I know for a fact hers does not turn off after 10 minutes because I have to turn it off for her every night after she has fallen asleep. Below is what Apple has to say about it from a troubleshooting standpoint.
"If music stops when the iPod nano screen turns off m Make sure the earphone port is free of debris. m Make sure the earphone or headphone connector is pushed in all the way. To see an illustration, go to support.apple.com/kb/ts3700."
Are you using aftermarket ear buds or speakers when you listen to these lectures??? If so maybe it has something to due with a compatibility issue. -
Sound drops off after 15 minutes after upgrading from windows 7 to Windows 8.1.
I upgraded my PC from Windows 7 to Windows 8. Then, from Windows 8 to Wimdows 8.1. When playing a Movie I've downloaded from iTunes it plays normally for a good while. Then, after 15 minuites or so the sound drops off. If I close and reopen iTunes it plays again for about the same time. I had to do that five or six times to get through a movie. I've tried installing the latest sound drivers, uninstalling and reinstalling the latests iTunes with no luck fixing the issue. I have my PC connected to my TV via HDMI cable. Any suggestions?
Hi,
You could download and install the trial version of Photoshop Elements 12.
For your serial number, try this:-
Go to Adobe.com and there should be a button to Manage account - click on that and sign in with your Adobe Id.
Click on View All under Plans & Products
Click on View other products
After a short while, you should see your Photoshop Elements appear and you can expand it to see your serial number.
The serial number can be entered into the trial version to activate it.
Do you have your catalog and images?
Brian -
I am getting a message in the middle of my imac screen instructing me to hold down the on-off button and turn off the computer. The message is in several languages and completely takes over the computer disabling the mouse and all other functions. The only option is to unplug the computer or turn it off. I'm concerned that this is a virus. It does not look like it's related to Apple or the imac OS.
That sounds like a kernel panic. These are generally hardware related, often caused by poorly seated or fauly RAM.
What is a Kernel Panic?
http://support.apple.com/kb/TS3742
and http://support.apple.com/kb/TS1892?viewlocale=en_US
http://developer.apple.com/mac/library/technotes/tn2002/tn2063.html
More details here:
http://www.thexlab.com/faqs/kernelpanics.html
Useful articles on how to avoid and eliminate kernel panics here:
http://reviews.cnet.com/8301-13727_7-10344626-263.html?tag=mfiredir
http://www.macworld.com/article/2027201/how-to-troubleshoot-a-kernel-panic.html# tk.nl_mwhelp -
Iphone 4 on/off button failure, what am I gonna do with it
on/off button does not work suddenly, home key is not working well neither. Shall I ask apple store help me with it?
Sounds like you're developing a hardware issue. Bring your phone into Apple for evaluation.
Maybe you are looking for
-
É possível criar cópia de segurança de todos os e-mails enviados pelo Thunderbird?
Eu gostaria que todos os e-mails enviados a partir de uma determinada conta (Vamos supor "Conta A") sejam também enviados para outra conta (Vamos supor "Conta B"). Eu sei que se eu for lá nas configurações da "Conta A", eu posso definir que sempre qu
-
At the time of CK40N what ever marked material few material not release
Hi At the time of Standard Cost Run in CK40N Time toal material 70, At the time of Marking total 70 material is marked, But at the time of Release time 65 materials only marked how to resolved this issue. Regards, R.Kumar.
-
Combined Upgrade & Unicode Conversion (Consistency & Scans)
Hi We are doing a combined Upgrade & UC conversion. 4.6C NUC to ECC6 eHP7 UC with an SLO MWB for Data. We have made a clone (System copy) of 4.6C and are running the SPUM4 tool on it (as per the guide) . My question: after I export the glossary from
-
Relocation of JDK & drastic performance slowdown?
Hi there, and thanks in advance for any suggestions: We are experimenting with redistributing the JDK (1.4, when released -- working with b2 a/t/m, will upgrade next week) as part of our product within our directory structure. With the Windows versio
-
Document properties and metadata
This question was posted in response to the following article: http://help.adobe.com/en_US/acrobat/pro/using/WS58a04a822e3e50102bd615109794195ff-7c67.w.h tml