Article View: borland.public.jbuilder.java.api
Article #2561Re: Play sound in application???
From: Gustavo
Date: Wed, 30 Aug 2000 00:00
Date: Wed, 30 Aug 2000 00:00
24 lines
1023 bytes
1023 bytes
Try this:
import java.applet.*;
public void playSound() {
AudioClip audioClip =
java.applet.Applet.newAudioClip(YOUR_CLASS.class.getResource("YOUR_FILE.WAV"
));
audioClip.play();
}
Using this, YOUR_FILE.WAV must Be in the same folder as YOUR_CLASS
"JBuilder" <kjhlove@elec.knu.ac.kr> escreveu na mensagem
news:3980d5e1_2@dnews...
> Hi..
> Now I'm trying to play sound in application. Not Applet.
> but I have no idea.
> Can you show me the way.
> Thanks for reading.
> ..
>
>
>
Technical Details
Message-ID:
<39ad69e9_1@dnews>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<3980d5e1_2@dnews>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1089d0,ce2bb6ac2ab4d5be X-Google-Attributes: gid1089d0,public From: "Gustavo" <gustavo@websee.com.br> Subject: Re: Play sound in application??? Date: 2000/08/30 Message-ID: <39ad69e9_1@dnews> X-Deja-AN: 664470815 References: <3980d5e1_2@dnews> X-Trace: 30 Aug 2000 13:09:13 -0800, 200.213.255.133 X-MSMail-Priority: Normal X-Priority: 3 Newsgroups: borland.public.jbuilder.java.api X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700