Online Training Spring Hibernate Training in Delhi R Programming Training Course Big Data and Hadoop Training Java Training  
 

java code to display in audio

Ads

 
 

Share on Google+Share on Google+

hari
java code to display in audio
1 Answer(s)      8 years ago
Posted in : Java Beginners
Ads
View Answers

November 25, 2008 at 12:32 AM


Hi friend,


Code to help in solving the problem :

import java.applet.*;
import java.io.File;
import java.net.*;

public class SoundExample {
public static void main(String args[]) {
try {
// Loop
URL url = new URL("http://localhost:3306/abc.au";);
AudioClip clip = Applet.newAudioClip(url);
clip.loop();
Thread.sleep(5000);
//SoundPlay
File file = new File("abc.wav");
clip = Applet.newAudioClip(file.toURL());
clip.play();
Thread.sleep(500);
System.exit(0);
} catch (InterruptedException e) {
} catch (MalformedURLException e) {
}
}
}


Thanks

Ads









Related Tutorials/Questions & Answers:
java code to display in audio - Java Beginners
java code to display in audio  Is their any java code, When i enterd text in text field , and when i press submit button,the text i entered should come in voice  Hi friend, Code to help in solving the problem
converter code for audio file
converter code for audio file  how can i convert a audio file to a another file format like mp3
Advertisements
java code to open and display MS-word document
java code to open and display MS-word document  java code to open and display MS-word document
Java how to stop audio
Java how to stop audio  hello i have this code in the main: try { AudioInputStream audio = AudioSystem.getAudioInputStream(new File...(audio); clip.start(); } catch
how to play audio track in java applat
how to play audio track in java applat  Sir,i took help of coding in how to play audio track in java applet....nd i found perfect code ..but when i run same code on net beans then it shows error that could not found main class
Play Audio in Java Applet
Play Audio in Java Applet       Introduction Java has the feature of the playing the sound file. This program will show you how to play a audio clip in your java applet
Audio Processing
Audio Processing  Sir, I want implement an audio recognition system by using java.. Is it possible? and tell me the process... thank you
Display Date - Java Beginners
Display Date  Plz send me sample java program that display day, date,year and crunent time. help me plz...  Hi friend, Code to display day,date,year and current time. import java.util.*; class DateExample
Display Java in JSP
Display Java in JSP  please i need urgent help. How can i display Java Applet created in netbeans in JSP?. the Application involves MYSQL Database connection. Thanks
code - Java Beginners
code  sir i want to design a audio and video player in java can you please give me instructions to do that project.. i want some sample code play audio and video in java please help me sir
image display - Java Beginners
image display  i need to display all the images from the folder and i dont want give the image path.dynamically it should display. please help  Hi friend, Code to help in solving the problem var
Display Data - Java Beginners
Display Data  I need sample how to display data from my table Mysql with swt/jface Thank you
code to display images using 2d array - Swing AWT
to display this using java code. I am relatively new to coding such requirements. Can anyone please tell me how to go about it ? Explanation of the code...code to display images using 2d array  HI !! I have an image file
java image display - Java Beginners
java image display  How to display images in the folder dynamically with out using database using java and jsp  Hi friend, Code to help in solving the problem var galleryarray=new Array
Display Image in Java
Display Image in Java     ...): Pass the boolean value as true to display the image or Vice-Versa. Here we are passing the boolean value as true to display the image on the frame
code to display 20 record per page and display page 1,2,3,4 as recoerd increase - JSP-Servlet
code to display 20 record per page and display page 1,2,3,4 as recoerd increase  Here is my code i wnat to diplay 15 to 20 records per page please... and previous button or display page no 1,2,3.. this is my code please any one
JAVA code For
JAVA code For   JAVA code For "Traffic signals Identification for vehicles
java code
java code  Create Product having following attributes: Product ID, Name, Category ID and UnitPrice. Create ElectricalProduct having the following... the Wattage and price of the electrical product. Display the updated ElectricalProduct
java code
java code  Create Book having following attributes: Book ID, Title, Author and Price. Create Periodical which has the following additional attributes... and the Period of the periodical. Display the updated periodical details
java code
java code  Create Vehicle having following attributes: Vehicle No., Model, Manufacturer and Color. Create truck which has the following additional... and loading capacity. Display the updated truck details
Java code
Java code  Create Product having following attributes: Product ID, Name, Category ID and UnitPrice. Create ElectricalProduct having the following... the Wattage and price of the electrical product. Display the updated ElectricalProduct
Java code
Java code   Create Vehicle having following attributes: Vehicle No., Model, Manufacturer and Color. Create truck which has the following additional... and loading capacity. Display the updated truck details
html parsing in java and display in swing
html parsing in java and display in swing  dear rose indians I am... HMTL pages in swing window forms to display html contents i am using... in JEditorPane. I am using the following code can you suggest me the other way
jsp code for display of data from database and snap shot of the output
jsp code for display of data from database and snap shot of the output  i am using JSP.i want to insert data into database and also want to display the things i have entered in the same page inside the corresponding fields
playing an audio file
playing an audio file  In playing an audio file we have to take one... how to solve this problem and also tell me where i should pass my audio clip path   Please visit the following link: http://www.roseindia.net/java
java code for given query
java code for given query  i am not able to display to display graph in all browsers it is only displaying in ie using java
java code
java code  what is the code to turn off my pc through java program
JAVA CODE
JAVA CODE  JAVA SOURCE CODE TO BLOCK A PARTICULAR WEB SITES(SOCIAL WEB SITE
java code
java code  write a java code to convert hindi to english using arrays
Java code
Java code  Create Book having following attributes: Book ID, Title... and the Period of the periodical. Display the updated periodical details.   Hi Friend, Try the following code: import java.util.*; class Book{ int id
java code
java code  hi any one please tell me the java code to access any link i mean which method of which class is used to open any link in java program