7 Replies Latest reply on May 1, 2011 1:35 PM by mathruD

    sound duplicates on top of itself when returning to home page

    mathruD Level 1

      i have a question about loading an mp3 in flash. the mp3 is loading & playing fine, but if i click a button to go to a new frame, and then click another button to return to the home page, a new copy of the same audio clip is loaded over the one that is already playing, thus causing two audio files to play at the same time. it will keep loading a new copy of the audio clip every single time i return to the home page. how do i go about correcting this? the following is the code i am using:


      var url:String = "testMusic.mp3";
      var urlRequest:URLRequest = new URLRequest(url);
      var sound:Sound = new Sound();


      red_btn.addEventListener(MouseEvent.CLICK, goSomewhere);
      function goSomewhere(event:MouseEvent):void {




      there is also a similar function that jumps back to frame 1 (the home page).