Need simple flash that plays a sound, urgent!

Hey,
I haven't worked with flash for a long time and don't have it installed on my computer... But I need a very simple flash to can play a sound once.
All it should do it so recive an url to a wav file and play it without display anything, thats it. So if anyone here could make on it would help a lot as I won't de able to do it myself.
It is very urgent and the background to this problem is that i have a website that should play a sound at a certain time but the technic I use now don't work on all computers/browsers/security setting (or what ever the problem is that I can't find). There was a complicated flash before that worked but it was  to hard to update with all logic so I had it replaced so that the logic is on the page and not in the flash.
Hope you can help me.
Filip

var snd:Sound=new Sound  ;
var channel:SoundChannel = new SoundChannel();
var isplaying:Boolean=false;
var req:URLRequest=new URLRequest(soundUrl.text);
var pos:Number=0;
loadSound.addEventListener(MouseEvent.CLICK,soundLoad);
function soundLoad(event):void{
snd.addEventListener(IOErrorEvent.IO_ERROR,ioerror);
snd.addEventListener(Event.COMPLETE,oncom);
snd.load(req);
function ioerror(e):void {
infoBox.text=e.text;
function oncom(e):void {
//infoBox.text="file is reday";
play_mc.addEventListener(MouseEvent.CLICK,soundplay);
pause_mc.addEventListener(MouseEvent.CLICK,soundpause);
stop_mc.addEventListener(MouseEvent.CLICK,soundstop);
function soundplay(e):void {
if (! isplaying) {
channel=snd.play(pos);
isplaying=true;
function soundpause(e):void {
if (isplaying) {
pos=channel.position;
channel.stop();
isplaying=false;
function soundstop(e):void {
if (isplaying) {
channel.stop();
isplaying=false;
pos=0;
Enter the file path  in the text field above
U can find the fla here  http://www.4shared.com/file/T1HuYo5N/sound.html

Similar Messages

  • Can someone provide a simple button which plays a sound for ios?

    I need a sample fla or the code for a button that plays a sound when touched, adobe air for ios.
    I have tried multiple tutorials and nothing seems to go right.
    a sample fla would be awesome.
    i used to be an actionscript 2 programmer so everything is new to me in actionscript 3.

    actually i just seen you cant put actionscript for iOS...is that true?
    well to develop this for android i have this code.
    but when i hit the button nothing plays, yet it plays find on the computer.
    import flash.events.MouseEvent;
    import flash.media.Sound;
    import flash.net.URLRequest;
    Multitouch.inputMode=MultitouchInputMode.TOUCH_POINT;
    var mySound1:Sound = new Sound();
    var mySound2:Sound = new Sound();
    var myChannel:SoundChannel = new SoundChannel();
    mySound1.load(new URLRequest("myFavSong.mp3"));
    mySound2.load(new URLRequest("myFavSong2.mp3"));
    mission_btn.addEventListener(TouchEvent.TOUCH_TAP, onClickPlay1);
    stop_btn.addEventListener(TouchEvent.TOUCH_TAP, onClickStop);
    ntl_btn.addEventListener(TouchEvent.TOUCH_TAP, onClickPlay2);
    function onClickPlay1(e:TouchEvent):void{
              myChannel.stop();
              myChannel = mySound1.play();
    function onClickPlay2(e:TouchEvent):void{
              myChannel.stop();
              myChannel = mySound2.play();
    function onClickStop(e:TouchEvent):void{
    myChannel.stop();

  • Any ideas why a film I have  converted to mp4 format, that plays with sound through my PC windows media file- only has a picture but no sound when transferred to my ipod touch via the Itunes?

    Any ideas why a film I have  converted to mp4 format, that plays with sound through my PC windows media file- only has a picture but no sound when transferred to my ipod touch via the Itunes?

    See:
    iTunes: May be unable to transfer videos to iPhone, iPad, or iPod
    iTunes: Frequently asked questions about viewing and syncing videos

  • A simple application that plays mp3

    does anyone knows how can i do an application in simple way that plays mp3 ?
    thanks

    see http://www.javazoom.net/jlgui/jlgui.html

  • Flash Player playing multiple sound feeds at once...even when browser is closed

    I recently updated my Flash Player to 11.3 (most recent version). When I go to a site which utilizes Flash (e.g. YouTube), I will start the video, and then about 10 seconds later, I get multiple sound feeds at the same time. They all sound like commercials, or tv channels. Even when I close my browser, the sound continues. When I open my sound mixer, there is a "program" listed of "winrscmde" which is playing the various audio channels all at once. When I go into the task manager, "winrscmde" shows as a svchost.exe *32. When I stop that service the sound stops. It will start again when i access a flash site. When I uninstall Flash Player 11.3, this stops.
    I'm running Windows 7 - 64 bit with latest updates. IE 9.0.8112.16421
    Any help would be appreciated.

    Well, I think I fixed the problem.
    I found this topic:
    http://www.bleepingcomputer.com/forums/topic442928.html
    About the second post down, the poster recommends downloading TDS killer as winrscmde.exe is disquised as svchhost.exe in the \windows\system32 folder (you have to click on "Properties", then "Details" tab and check the original filename...if it's bogus, it'll say winrscmde.exe as the original name).
    I also ran the aswMBR program as well as FixTDSS (http://www.symantec.com/content/en/us/global/removal_tool/threat_writeups/FixTDSS.exe).
    That seemed to fix the issue. Just reinstalled Flash and don't get the same issues. The svchost.exe in the \windows\system32 folder is legit!
    Hope that helps anyone else with the same problem.

  • Flash button play over sound in both over and down states?

    I have created a button and set a sound on it for the over
    state. The sound plays correctly when the button enters the over
    state, but it plays again when the button enters the down state.
    Here's what I did as a test:
    In an empty Flash9/ActionScript3 project:
    1. Create a new button symbol
    2. Insert key frames for up/down/over/hit
    3. Draw a rect on each of those keyframes (just for testing
    purposes so you can see it)
    4. Go to over state and set the Sound property to a sound in
    the libray. Set effect:none, sync:event/repeat/1
    5. Verify that the down state still says sound:none
    Now put that symbol in the scene and try it out. For me the
    over sound will play both when you mouse over the button and when
    you click on it. Does this make any sense?

    bump for help.

  • Who has a link to free Flash? I need Adobe Flash to play videos.

    I need Flash to view videos.

    No Flash for iPads, iPhones, or iPods
    Here's why there's is no Flash available for iDevices or other mobile devices. Adobe was unable to provide a product that was suitable to the needs of battery powered mobile devices used for Internet browsing. Existing Flash technology used too much memory, ate battery life, and was buggy. Simply put Flash did not work well on mobile devices.
    Apple's Steve Jobs led the escape from Flash dependency when Apple introduced the iPhone, and later introduced the iPad. There was a hue and cry over the omission. Time proved Jobs was right on target.
    So this is why there is no Flash for your iPhone or iPad or iPod nor for most SmartPhones. Flash has been abandoned by many sites in favor of supported technologies such as HTML5 or by providing their own custom app.
    Here is Steve Jobs official comment on his momentous decision to omit Flash from iDevices: Steve Jobs on Flash.
    Here is Adobe's later announcement to cease development of Flash for mobile devices: Adobe on Mobile Flash. Adobe is not providing Flash for Apple iOS devices, and they no longer provide Flash for any other cellular phones. Flash is officially gone.
    Now, you are not necessarily out on a limb. There are some apps that can display some Flash, but don't count on there ability to display anything using Flash.
    A sample of Apps that can display some Flash content:
      1. Puffin
      2. SkyFire
      3. Photon Flash
      4. Browse2Go
      5. Swifter
    Also, note that many sites that use Flash provide their own app for accessing their material. So check with your favorite sites and find out if "there's an app for that."

  • I need a Flash expert to help me urgently!

    This is a long shot and forgive me if I'm posting in the wrong forum-
    I am a web designer and I have a client who has asked me to do a project for him very quickly in Flash. He's given me a template and, whilst Flash isn't my strong point, I've been fine customing it for him as he wanted it.
    But now I'm totally stuck because he wants me to work with the action script and I've come completely unstuck. If I was working in Dreamweaver I'd be fine, and I have a feeling the problem would be a piece of cake to a Flash expert.
    Is there anyone who could spare me 10 mins of their time? I could zip up the template and let them have a look at it?
    If this is the wrong place then can someone suggest somewhere I else I could go?
    Be kind to me!
    Claire

    let me look at your file
    Can you give me the file
    I will try to help you But don't be sure i am middle level AS3 and i am learning form this forums.

  • How to pause, stop, play a sound that is loaded from the other .swf file?

    Pause and Resume external SWF sound files
    I have this code that plays the sound through linkage. It reside in scene1.fla -> scene1.swf.
    var mc:MovieClip = this.createEmptyMovieClip("mc",1);
    var myLoop:Sound = new Sound(mc);
    myLoop.attachSound("bg_sound");
    myLoopVolume=0;
    myLoop.setVolume(myLoopVolume);
    mc.onEnterFrame = function () {
        if (fadeIn01==1) {
            _root.myLoop.setVolume(myLoopVolume);
            myLoopVolume=myLoopVolume+5;
            if (myLoopVolume>50) {
                fadeIn01=0;  
        if (fadeOut01==1) {
            myLoop.setVolume(myLoopVolume);
            myLoopVolume=myLoopVolume-1;
            if (myLoopVolume<5) {
                _root.myLoop.setVolume(10);
               // _root.myLoop.stop("myLoop01");
                fadeOut01=0;
    fadeIn01=1;
    myLoop.start(0,999);
    The problem goes like this. I want to pause the sound from playing in scene1.fla -> scene1.swf in anytime I want, through my main.fla -> main.swf that loads the scene1 movie. I got stuck.

    you need to use the path from the timeline that contains the controlling code and myLoop.  you can always use trace(this) on both timelines (the one containing the controlling code and the one containing myLoop) to determine the correct path.

  • Is it possible to... make a movieplayer that plays wmv and asf files?

    I have Flash 8 Professional. Is it possible to make a player
    in flash that plays wmv and asf files without first converting them
    to flashvideo? If so, where can I get info about this challenge?

    2m wrote:
    > Sorenson Squeeze should be able to do it for example.
    There might be others out there that's just the one I have
    The macromedia Standalone Encoder does it.
    It can process multiple files in the same time as well.
    (comes along with Flash 8 installation)
    Best Regards
    Urami
    <urami>
    If you want to mail me - DO NOT LAUGH AT MY ADDRESS
    </urami>

  • My iphone has been lost in my house and i need to find a way to track it and its offline. it wont connect to the internet so there isnt a way to use find my iphone. i just want to play a sound on it. is there any way i can get a app that connects my ipod

    my iphone has been lost in my house and i need to find a way to track it and its offline. it wont connect to the internet so there isnt a way to use find my iphone. i just want to play a sound on it. is there any way i can get a app that connects my ipod from a laptop or a different way to find it.

    If your phone is offline, the ONLY way to find it is to look for it the old fashioned way.  Your phone CANNOT be located electronically if it's offline.

  • I have an ebook that needs a flash player to play? Is there anyway that that next update will be a le to read this type of format

    I have an ebook that needs a flash player to play? Is there anyway that that next update will be a le to read this type of format

    Johnathan Burger wrote:
    No.
    Flash is never coming to ios.
    Adobe has discontinued mobile flash for all devices.
    Take a look at bluefire reader.
    Wow, are you serious?
    That really ***, I have been playing with mine and can't believe I can't use 3/4 of the sites I like on it.
    My Android tab runs Flash just fine, and has done so for 2 years. Are you suggesting one day Adobe is going to break in my house and uninstall it?
    I don't understand this at all, it seems at every turn I try to use this thing like my android tab and I simply can't, all I've found so far to actually be able to do is use iTunes for everything... pretty lame and something I'm not going to do when I can get this content free on all my other devices.
    This is truly a shame. I was really hoping I was just doing something wrong. Glad I only spent $50 on it at a garage sale.

  • 4 Simple Flash Questions that Are Stumping Me!

    What is the Frame Rate for Web Animations
    Q1. I am making an animation which will be played on the web. What is the default frame rate (fps) of Flash CS5? And what is the frame rate of for web?
    Q2. My animation needs to be 30 seconds long. So at 15 fps that would mean I need to use 600 frames in Flash?
    How Do I Mask everything so all I see is the Content on the Stage?
    I have a wide image that extends past my movies stage size so when I preview my movie the image is visible. How do I mask out anything that extends past my movies window size? I believe I can create a layer named "mask" and place it above all other layers, but I forget how to make the mask. Any help is appreciated.
    How to Fade a Graphic
    I have a graphic element (some type) and I want it to fade from 0% to 100%. In older versions of Flash I could just select the symbol and then set it's alpha value to 0%, move a few keyframes and then set the alpha to 100%. Voila! but now it doesn't seem to work that way. How can I do this in CS5?

    Ned, it says 24 fps which means there is 24 frames per second so each 24 frames is 1 second.
    Date: Fri, 4 Nov 2011 05:35:16 -0600
    From: [email protected]
    To: [email protected]
    Subject: 4 Simple Flash Questions that Are Stumping Me!
        Re: 4 Simple Flash Questions that Are Stumping Me!
        created by Ned Murphy in Flash Pro - General - View the full discussion
    1 You can create your character as a movieclip and copy/paste that movieclip from one file to another. 2. One way to create a movieclip is to copy all the frame of the animation's timeline (select them all, right click the selection, choose Copy Frames), then create a new movieclip symbol (Insert -> New Symbol...etc) right click on its only keyframe and chhose Paste Frames.  THat will put all the layers and frames you copied into the movieclip The only way to come close to being certain about the timing of you animation is to use code to keep track of the time, something like getTimer()..  The frame rate that a file plays at is not a reliable means of dictating the time it takes due to a variety of factors which include the amount of content you are trying to process and performance limits of the user's machine.
         Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/4007420#4007420
         To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/4007420#4007420. In the Actions box on the right, click the Stop Email Notifications link.
         Start a new discussion in Flash Pro - General by email or at Adobe Forums
      For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.

  • Play a sound on mouseover in an html canvas document in Flash CC

    Hi,
    I've been looking for quite some time to do something that I'm sure is simple, but I can't find the answer. I'm sorry if I missed it, but I appreciate any help anyone can provide.
    I have a simple button in flash that I am converting to an html canvas document so I can place it as html in my website with animation and sound on mouseover. I got the animation working the way I want it when I publish to html, but using Actionscript 3, I had a sound that played when the user moused over the button. I want to have it still play a sound when the user mouses over it in my html canvas file too, but I have not had success yet with converting my Actionscript to Javascript and am not a javascript expert by any means. I would also like to have multiple formats of the audio file linked in the code for any browsers that don't work with mp3 files. I can convert the audio file no problem but don't know how to code this…. I have found a few general tutorials on this, but have not been able to get it to work with anything I've tried so far.
    Here is the Actionscript code I had which works fine in my original document when I export as a .swf file.
    stop();
    import flash.media.Sound;
    import flash.net.URLRequest;
    import flash.events.Event;
    sprayGunbtn.addEventListener(MouseEvent.MOUSE_OVER, playSound);
    var myExternalSound:Sound = new Sound();
    var req:URLRequest = new URLRequest("ShortSpray.mp3");
    myExternalSound.load(req);
    function playSound(event:Event){
      myExternalSound.play();
    If someone could help me convert this to Javascript so that it will work when I publish my .fla file to html, I would greatly appreciate it. Thanks very much in advance for your time….

    You can follow the below steps to easily play a sound at runtime - like on mouseover.
    1. Make sure your audio is imported in library and has a linkage name specified.
    2. Open Windows Menu -> Code Snippets panel and expand HTML5 Canvas -> Event Handlers section.
    3. Select your button on Stage and apply the MouseOver Event from Code Snippets to it.
    4. In the MouseOverHandler function add the below line and test movie:
              playSound('audio_linkage_name');
    If you still face problems let me know.
    Also, you might want to go through the SoundJS documentation for more control with Audio in HTML5.

  • Where can i find simple flash play/stop button tutorial

    Can anyone help me where can i find simple flash play/stop
    button tutorial. All i need to import a icon play/stop button, when
    click it load wav file.
    How can i attach media.fla
    when u click btn
    on(release) {
    CodePlayer.start();
    on(release) {
    CodePlayer.stop();
    action script
    CodePlayer = new Sound();
    CodePlayer.loadSound("ContactUs.wav",true);

    OK your sorta close. the .wav file "ContactUs.wav" couldn't
    be too large a file, and you can't use 'loadSound' with a .wav, it
    would need to be an mp3 file and you also have it set to be a
    streaming file, which I would image is not necessary.
    So under File>>import select the wav file and add it to
    the Library. Select it, right click, and select 'linkage'. Enter a
    name for the identifier like 'contact_id' and hit OK. Now go back
    to your code on frame one, main timeline and change the code you
    have to:
    var CodePlayer:Sound = new Sound();
    CodePlayer.attachSound("contact_id");
    Now in your button handlers change to:
    on(release) {
    _parent.CodePlayer.start();
    on(release) {
    _parent.CodePlayer.stop();
    }

Maybe you are looking for

  • "Mac Help" no longer works.  It just spins and spins and spins.

    Today my Mac Help stopped working. I open Mac Help, type in a query, and it just spins and spins an dspins an never returns a result or fails. For the life of me I can't figure out what is wrong. Any ideas?

  • Problem with client_get_file_name

    Hi, v_filename := client_get_file_name(........); :b_test.test := v_filename; Above is the simple code that I use. But my problem is ... sometimes ( I think 1 out of 10 ), when I select the file in the dialogue and press open button, the dialogue clo

  • Creating a new message in adapter module

    Hello, I already posted the question in this [Thread|Sending Adapter Module to split messages;, but I now create this new topic so you can get points for your answer Jan from this thread wrote "I know how to send a new message using a new instance of

  • How do i clean fingerprints off my iMac 27" screen?

    I have the 27" late 2012 model iMac and was wondering how to clean fingerprints off the screen.While my family does a videochat we kinda move the scrrenup,down,left or right to view the whole room and nov there are fingerprints on the screen.If i cle

  • ANOTHER iphoto black hole thread

    Hello. I had about 8,000 photos in the summer and when I moved to Copenhagen I took my library from my iMac onto a USB drive, and that's where the library is now. One of the first times I use iPhoto after arriving, all those old 8,000 photos ended up