Skip to main content
December 9, 2015
Answered

How to make the background sound auto replay when user return to the page?

  • December 9, 2015
  • 1 reply
  • 560 views

Hi. I am making a flash project by using Adobe Flash CS6 and AS3. I insert background sound in every scene. However, I had put one command for the bg sound to stop in every scene. But the problem is when user return back to the previous page, the sound doesnt play. Anyone know how to make the background sound replaying when user return without any on/off button etc? Thanks in advance!

This topic has been closed for replies.
Correct answer nezarov

var mySound:Sound = new Sound();
mySound.load(new URLRequest("sound.mp3"));
mySound.play();

1 reply

nezarovCorrect answer
Inspiring
December 9, 2015

var mySound:Sound = new Sound();
mySound.load(new URLRequest("sound.mp3"));
mySound.play();

December 9, 2015

Thank you for your help!

Inspiring
December 9, 2015

You're welcome.