32,204 Topics

Member Avatar for
Member Avatar for AlbertPi

The following method "sound" works on my PC and it sounds a beep. I am using java 1.5 and Jdeveopler 10.1.3.4 on Windows XP/SP2. import javax.sound.sampled.*; public void handleBeep(ReturnEvent returnEvent) { try { sound(2000,150); } catch (LineUnavailableException lue) { System.out.println(lue); } } public static void sound(int hz,int msecs) throws LineUnavailableException …

Member Avatar for AlbertPi
0
224
Member Avatar for das_das

hello I have attended SCJP 5.0 and SCJP 6.0 Mock test at , it good one at [link removed] 10 sets of mock test i have attended... I want to attend more mock test before actual exam.. can anybody please tell me where can i attend ? thanks das

Member Avatar for peter_budo
0
99
Member Avatar for gadisandeep

Hi,I am reading this .CSV file and new to this.I have information in tabular form where i have names in 1row and 1column and in between cells i have numbers indicating links of those names by that purticular number. I want to retrevie those names who are having that purticular …

Member Avatar for Tyrone.Wilson
0
109
Member Avatar for dayotjawak
Member Avatar for jessxe02

Help I want to learn how to connect SQL to my java program? is there any free online tutorial? help my please..

Member Avatar for sierrainfo
0
153
Member Avatar for christiangirl

I have to write two programs, one writes to file based on what the user selects. The other reads the file, and outputs what the user selects. And I'm really not sue if I'm doing this right. Here is what I have for writting to the file: [code]import javax.swing.*; import …

Member Avatar for vee_liang
0
84
Member Avatar for christiangirl

I have to make a program where I take a file that contains users order information(the file is from another program I had to make), and then tests it and outputs how many of what it orders. I cant seem to get it to work, its running but then at …

Member Avatar for masijade
0
81
Member Avatar for Acidburn

Hey guys, I've found this article showing how to manipulate itunes using java and com objects. However I dont really understand how it works, and can't seem to tell java to send a play / pause request. The event listeners works. [url]http://www.workingwith.me.uk/articles/java/itunes-com-with-java-and-swing[/url] Could someone try and expand on this? Or …

Member Avatar for priyankalakhe
0
145
Member Avatar for orangejuice2005

Hello, I am writing a program that will read in a pair of inputs, (P, S), summarizing the results of a code inspection. One input is the integer problem number, P, and the other is the severity level, S, of that problem. Since a typical code inspection will never have …

Member Avatar for christiangirl
0
146
Member Avatar for vman6ley

Hello, First I'll like to say that this a fantastic site for newbies and I'm sure for seasoned programmers as well. I have gained a lot of insight by just reading the threads and for this I thank Daniweb. Thank you very much in advance for your expert help. My …

Member Avatar for vman6ley
0
109
Member Avatar for prabhurangan

Dear Members, I found a thread named 'Execute an sql script in jdbc' it was very much useful to me. However i have my routines(ie. stored procedures and functions) also with the backup.sql file. This is the link which i looked for: [url]http://www.daniweb.com/forums/thread153923.html[/url] But i have to execute my script …

Member Avatar for Ezzaral
0
72
Member Avatar for cproud21

I have a GUI app which in which I need to pass a value from an array to a List... here is what I have... The problem occurs when I try to pass the array element to the ActionListener... im not sure exactly how to do it... [ICODE] import java.awt.*; …

Member Avatar for LDeArm
0
150
Member Avatar for detoxx

Can anyone help me please? i need to create a program in which you enter a distance and the program will tell you how long it will take to get there in hours minutes and seconds. My trouble is that they all display independently and not seperately ... for example …

Member Avatar for sillyboy
0
265
Member Avatar for 00matt

Hi, I am new to java and would really appreciate it if someone could look at the code I have attached. This is part of a java lab assignment that I have got to do for university. For reference, I have also uploaded the lab file. I am trying to …

Member Avatar for jasimp
0
142
Member Avatar for Anselm

Is there an API I can use to program a flow diagram? My need to develop a table flow diagram from database data collected in a excel spread sheet. I need to parse the table joins and generate a flow diagram. The program is an attempt to keep our diagrams …

Member Avatar for Ezzaral
0
186
Member Avatar for peter_budo

In the JFrame I have two components JMenuBar and JPanel. A selection in one of the options in menu bar change the content of panel as [code=Java]JMenuItem jmiAddEmployee = new JMenuItem("Add Employee"); jmiAddEmployee.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent ae) { mainPanel.removeAll(); mainPanel.add(addEP); validate(); } });[/code] This will replace the content, …

Member Avatar for peter_budo
0
173
Member Avatar for sriram.19801980

Can some someone help me with a code to create a new Excel workbook and send data to the workbook using[B] java[/B].Please help me.

Member Avatar for Ezzaral
0
291
Member Avatar for localp

I want to know how to call the above function ??? [code] import java.awt.*; import java.applet.Applet; import java.awt.event.*; public class GridDrawingApplet extends Applet { public void paint (Graphics g) { // Draw the vertical lines: g.drawLine (0,0, 0,240); } } public static void main(String []args) { // now i want …

Member Avatar for anil_forum
0
117
Member Avatar for AlbertPi

This is my function. see below: public void SoundTest() { try { AudioInputStream audioInputStream; File file = new File("C:\\Temp\\online.wav"); audioInputStream = AudioSystem.getAudioInputStream(file); Clip line; line = (Clip) AudioSystem.getLine(new DataLine.Info(Clip.class, audioInputStream.getFormat())); line.open(audioInputStream); line.start(); line.drain(); audioInputStream.close(); } catch (Exception e) {e.printStackTrace();} Toolkit.getDefaultToolkit().beep(); } I got this error when I ran it: ` …

0
72
Member Avatar for superbob7

I was messing around trying to figure this out and came up with this. This works but I'm looking for a more elegant recursive solution. Can anyone think of one? I couldn't find anything with google. Oh and sorry for the stupid variable names. [code=java] public class arraybackwards { public …

Member Avatar for peter_budo
0
734
Member Avatar for anil_forum

can any one tell me that how to get the names of all the computers connected in a workgroup using java. how to get the ip address of the computers connected in a LAN

0
87
Member Avatar for localp

i am an absolute beginner in java . i want to generate a javadoc , i am using JCreator, so can your'll give me step by step instructions on how to create it... i googled but couldn't find a better one... and dont forget that i am an absolute beginner …

Member Avatar for stultuske
0
63
Member Avatar for sachein

hi all I am new to java,i want to create exe file for my jarfiles.I want the same for web based and stand alone application .can any body please explain the above

Member Avatar for stultuske
0
109
Member Avatar for jspar090

Hello, I am cooking up an application that when I first thought of figured would not be difficult. Basically, what I am thinking of is an application that will track the growth of several of my mothers orchids (I know it is kinda of weird, but this is something that …

Member Avatar for jspar090
0
77
Member Avatar for ishaanviegas
Member Avatar for stultuske
0
90
Member Avatar for AsantaSane

Hey there, this is my first post here and I'm in the need of some real help. I've written a basic password verifier, which checks to see if what you type in is the same as the default stored password, but i continually get a compile error. [CODE]import java.util.Scanner; public …

Member Avatar for stultuske
0
995
Member Avatar for mangoxoxo

ASSIGNMENT: In section 6.1 of the text, the authors explain how to compute the distance between two colors. They write, The Pixel class has an object method colorDistance(Color color) which returns the distance between the color in the current Pixel object and the passed color. Write a method which takes …

Member Avatar for mangoxoxo
0
117
Member Avatar for MxDev

hi guys, is it possible to distribute a mysql database and java application together without need the server to run the database from, is there's a way around to make this happen?? Thanks in advance

Member Avatar for masijade
0
41
Member Avatar for mansoorhacker

hello forum members. i want to find the code behind the builtin length() method of the strings. actually i want to find the length of the string wihtout using the builtin length method of the string in java. thx,

Member Avatar for masijade
0
57
Member Avatar for mabros86

hey guys!!! okay!!! i have a problems that this program is to build to choose a file and the copy it exactly to a new file of my choice but the only is that everytime i do that it happens to make a mistake it copies the file into the …

Member Avatar for mabros86
0
356

The End.