32,204 Topics

Member Avatar for
Member Avatar for BestJewSinceJC

edit: I see a lot of other threads on Daniweb on this. But after 2+ hours of reading about Sound in Java, I'm even more frustrated, so I have some questions. 1. Is the Java Sound API sufficient for the following operations: Playing mp3 audio files, pausing, and fast forward/rewinding …

Member Avatar for BestJewSinceJC
0
489
Member Avatar for chatgro

I was Writing a code to connect data base and add the following code to my action.java Connection connection=getConnection("UserBook","UserBook123","catalog","localhost"); String sql="select BookName from book"; PreparedStatement ps=null; ps=connection.PreparedStatement(sql); ResultSet set=ps.executeQuery(); while(set!=null&&set.next()) { System.out.println(set.getString("BookName")); } connection.close(); the error i get is "The method PreparedStatement(String) is undefined for the type Connection" Need to …

Member Avatar for VernonDozier
0
98
Member Avatar for ryy705

Hello, I am trying to create a simple ftp client. I'm following the instructions from [URL="http://www.nsftools.com/tips/JavaFtp.htm"]http://www.nsftools.com/tips/JavaFtp.htm[/URL](option 4) If you take look at JakartaWrapperTest.java, The first line is import JakartaFtpWrapper; So When do javac JakartaFtpWrapper.java JakartaWrapperTest.java -cp commons-net-ftp-2.0.jar I get an error saying [B]'.' expected[/B]. And if I comment out the …

Member Avatar for ryy705
0
269
Member Avatar for jdfskitz

heres the code i put [ICODE] import java.net.URL; import com.sun.j3d.loaders.*; import com.glyphein.j3d.loaders.milkshape.MS3DLoader; public class shoulders { try { Scene s = null; Loader loader = new MS3DLoader (MS3DLoader.LOAD_ALL); // .ms3d Loader java.io.File file = new java.io.File("./model.ms3d"); if (file.getParent().length() > 0) loader.setBasePath(file.getParent() + java.io.File.separator); Scene scene = loader.load(file.getName()); BranchGroup group = …

Member Avatar for jdfskitz
0
105
Member Avatar for simplypriti

Hi all, I need information of a better Java hosting service (better in terms of performance, security, storage, reliability). I do not want to compromise with performance and reliability/security. So if any of you know such kind of service provider thn kindly let me know ASAP. It would be great …

Member Avatar for simplypriti
0
142
Member Avatar for puneet88

i want to make a project on "project distribution system for any company", for which i need to include database my problem is that where to start ...what to do ....?? can we make this online ..???

Member Avatar for lordspace
0
111
Member Avatar for Web_Sailor

Hi, I want to convert a Treepath into a String so that I can use it for IO operations ... How can I do it ? Suppose I have a Treepath variable like this:- [CODE]TreePath path = m_tree.getPathForLocation(x, y)[/CODE] Thanks in advance

Member Avatar for JamesCherrill
0
91
Member Avatar for anumitadas
Member Avatar for VernonDozier
0
81
Member Avatar for anumitadas

Plz Help me to print in [B]java [/B] a b a b c b a b c d c b a b c d c b a b c b a b a

Member Avatar for VernonDozier
0
308
Member Avatar for mossman mudas

this is two questions: list the order of the threads. i am not sure of the answer but i have included my thinking, thanks. Thread State Priority threadA Runnable 5 threadB Sleeping 5 threadC Sleeping 5 threadD Waiting 5 threadE Runnable 5 ANSWER: A,E,D,B,C Thread State Priority threadA Runnable 5 …

Member Avatar for kvprajapati
0
130
Member Avatar for MonicaClare

hi to all programmer... i have a problem about this program .. an error exist .. [code="java"] import java.io.*; import java.awt.Graphics; import java.util.Random; import javax.swing.*; public class midquiz 2{ // "{" expected public static void main (String [] args) throws IOExeption{ BufferedReader 9new InputStreamreader (System.in)); String name,pass,ans; String pass1="pOLOtAn"; int …

Member Avatar for puneet88
0
185
Member Avatar for fullgl

import.java.util.Scanner; <Error This ?> [<identifier> expected] class Work3_2 { public static void main(String[] args) { Scanner input=new Scanner(System.in); String carid; int park,pay; int parked; System.out.print("Enter Car ID : "); carid=input.next(); System.out.print("Enter Parking Times : "); park=input.nextInt(); parked=park*60; if(parked <=15) pay = 0; else if(parked >15 && park <=60) pay=20; else …

Member Avatar for javaAddict
0
63
Member Avatar for guyod

Hi, i was wondering what would be the best way of reading a single line from a text file? For example, i have a file that contains the following data: dog cat bird deer How can i read the 3rd line of the file? I was thinking that i would …

Member Avatar for ~s.o.s~
0
111
Member Avatar for choybutchoy

hi guys, how can I retrieve the total record count from a database? I mean is there a method like "rst.recordCount"? or whatsoever? thanks...

Member Avatar for choybutchoy
0
125
Member Avatar for jdfskitz

I just Started Java BUT I'M FOR SURE I CAN GET A HANG OF THIS! ive typed these pages out and Cant Find the Problem.. I NEVER START OUT EASY!! SO FAR EVERY TIME I START OUT EASY I LOSE WHERE I AM!! so this is a rotating 2d picture.. …

Member Avatar for jdfskitz
0
212
Member Avatar for buchanan23

Hi everyone. So here is my dilemma, I am working on my final project, tackling it one item at a time, so this post is strictly for help deleting a record out of my array. I think I have everything set up right to call to a Method I am …

Member Avatar for buchanan23
0
112
Member Avatar for Web_Sailor

I donno why I am not able to get the popup for this JTree. This tree is found almost in all tutorial ? [CODE]import java.awt.*; import java.awt.event.*; import java.io.*; import java.util.*; import java.text.SimpleDateFormat; import javax.swing.*; import javax.swing.tree.*; import javax.swing.event.*; public class FileTree2 extends JFrame { public static final ImageIcon ICON_COMPUTER …

Member Avatar for Web_Sailor
0
186
Member Avatar for Amitji

Hi All I am developing a application n having a serious problem. Think we have opened some running applications like text document and after a particaular time i want to autosave data from that application at a default path.Pls try to solve me this problem Thanks in Advance

Member Avatar for peter_budo
0
844
Member Avatar for beshoyatef

I try to draw line with this code but it never appear say to me the correct way for doing this . This is my code: [ICODE]public class MyMouse extends JFrame { private JPanel mainPenl; private JPanel paintPanel, componentsPaintPanel, areaPanel, areaPaintPanel; String[] buttonsName = {"Line", "Oval", "Rectangle"}; JButton[] paintButtons; MyMouseAdapter …

Member Avatar for JamesCherrill
0
125
Member Avatar for akulkarni

i wish to add another column using code in JDBC.I have one column columnname i wish to add a text type(data type in access) column in the access file my code is [code] import java.sql.*; public class Test3 { public static void main(String[] args) { try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); /* the …

Member Avatar for akulkarni
0
153
Member Avatar for ezkonekgal

Hello every one. Basically i am trying to construct a binary tree. but there's a problem. When i run the program, there is an error. somewhere in the treeInsert method(). I am having difficulty because the root is not node, it is an integer value. then the left and right …

Member Avatar for JamesCherrill
0
224
Member Avatar for recycle_carlbin

Hi. There is something wrong with the codes of my levelOrder method. Can anybody help me identify the wrong stuff out here? By the way, I also have another problem,what are the uses of setters? I teacher require us to put getters and setters but then I am totally confused …

Member Avatar for recycle_carlbin
0
127
Member Avatar for rizzo000

We have this program we are supposed to write that takes input from a file with a random word puzzle throws it into an array and prompts the user for a word input or to quit. So far I can get the program to find elements in forward/reverse, up/down, by …

Member Avatar for rizzo000
0
238
Member Avatar for jooa

Hi, I have written two classes. One is a pixel grabbing class the other allows the user to open and display an image. What I now want to be able to do is use the image which the use opened in the RunProgram class and grab pixels from it using …

Member Avatar for jooa
0
116
Member Avatar for keziaebitner

using dialog boxes : input month in "99" form date in "99" form year = 2009 then display the date in 'MMM 99, 2009' form otherwise, display 'invalid date' Valid date 01-12 = Values for month 01-28 = for month - 2 01-30 = for months - 4,6,9,11 01-31 = …

Member Avatar for campbellm
0
93
Member Avatar for anu6189

Hey all, ive been searching for a long time and i want to know how am i suppose to display an image that is stored in the database(SQL) in swings in java. i inserted the data in the database as a image datatype(i hope thats right),now the thing is i …

Member Avatar for anu6189
0
236
Member Avatar for NewToThis

I've been trying to build a java program to display the date in a MM/DD/YYYY format with constructors to link the return data, this is the initial sequence and was wondering about my get and set statement; and their format. // Date class with a constructor to // to initialize …

Member Avatar for JamesCherrill
0
74
Member Avatar for bigbadbag33

hi; I am trying to create a program that will return information stored as long as the word stop is not entered for the employee name, I cant get the program to work can some one help me with this. this what I have so far. // payroll program upgrade …

Member Avatar for bigbadbag33
0
103
Member Avatar for GregStoltz

Hey everybody :) So im new to programming and im using the jDateChooser from the com.toedter.calendar package the problem that I am having is that I am not able to get the current date to display ... you have to just select the date yourself ... can anyone give me …

Member Avatar for quuba
0
195
Member Avatar for seanl1

So I was going through the course archives for our CS program and looked at some notes and quizzes from a class that was last taught in Spring of 2008 that I will be taking Fall of 2009. It's called Survey of Programming Languages and I found the section on …

Member Avatar for onaclov2000
0
160

The End.