wood burning stoves*
The moose likes Other JSE/JEE APIs and the fly likes play audio in loop Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Reply locked New topic

play audio in loop

nayan rami
Ranch Hand

Joined: Dec 28, 2010
Posts: 30
hello friends

can any one provide me code for play audio in loop in java application not in applet

i need this code urgently

Rob Spoor

Joined: Oct 27, 2005
Posts: 19651

1) We are NotACodeMill
2) EaseUp

You can still use AudioClip even if you're not using applets. Instead of using Applet.getAudioClip you can use the static Applet.newAudioClip(URL) method. This takes a URL, but you can convert a File into a URL quite easily:
But because the method takes a URL you can also use the getResource method of Class / ClassLoader.

How To Ask Questions How To Answer Questions
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 41102
Please do not post the same question multiple times. Let's continue the discussion in this duplicate thread. If you have questions about the answers provided there, post follow-up questions in that topic.

Ping & DNS - my free Android networking tools app
wood burning stoves
subject: play audio in loop
Similar Threads
Is there a way to loop until AudioPlayer has stopped?
Java Sound API problems
Getting audio to play in the background of my GUI.
How to play audio in the background
Quit audio before application exits.