Hi,
Thank you for response.Yes,the browser is downloading the file.
The code i'am using is given below:
------------------------------------
package Sound;
import java.io.IOException;
import java.net.*;
import java.applet.*;
public class Sound2{
public static void main(
String a[])
{
try {
String str1="http://simplythebest.net/sounds/WAV" +
"/WAV_files/cartoon_WAV_files/aladdin_goodbye.wav";
String str2="file:\\C:\\Documents and Settings\\btripathi" +
"\\Desktop\\ChatRoom_15April_Backup\\client\\sound\\ringin.wav";
URL url=new URL(str1); // 1
AudioClip clip =Applet.newAudioClip(url);
clip.play();
}catch(java.net.MalformedURLException e)
{
e.printStackTrace();
}
}
}
---------------------------------------------
Now when i pass str1 (as shown in //1) it,s workin fine,But whenever i pass str2 or whole URL("http://....").I'am unable to hear any sound.Even i'm not getting a single error.
[ July 05, 2007: Message edited by: yoshino ]