This week's book giveaway is in the Jobs Discussion forum.
We're giving away four copies of Java Interview Guide and have Anthony DePalma on-line!
See this thread for details.
The moose likes Applets and the fly likes sound Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Applets
Bookmark "sound" Watch "sound" New topic


Stephanie Grasson
Ranch Hand

Joined: Jun 14, 2000
Posts: 347
Hi all!
I am trying to play a sound when the user clicks a button in my applet. I am using the following method:
AudioClip myAudio = getAudioClip(getCodeBase(), "chord.wav");;
I don't get any errors or warnings, but no sound is played.
The button works properly (I tested it by printing text to a TextArea on my applet whenever the button was pressed).
Any ideas?
Thanks in advance.
Thillai Sakthi
Ranch Hand

Joined: Jun 17, 2000
Posts: 103
Hi Grasson!
Why don't u give in a little bit code what u are trying to work on. so that it would be easy to understand what exactly is the problem.(Of course if u still persist with the problem.

I agree. Here's the link:
subject: sound
It's not a secret anymore!