Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

sound

 
Stephanie Grasson
Ranch Hand
Posts: 347
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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");
myAudio.play();
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.
Stephanie
 
Thillai Sakthi
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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.
Tks.
Kumaresan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic