32,199 Topics

Member Avatar for
Member Avatar for Tiny_trixer

The program I'm supposed to make a program where one thread starts three other threads. The original thread is going to wait until the three other has finished running and then the first thread can stop. The way I've built the program the three threads is started from one class, …

Member Avatar for Tiny_trixer
0
143
Member Avatar for meowbits

Probably easiest if I just quote, [QUOTE]5) Assignment Entity, A class that models an association between an Employee and a Project Each project usually has several employees working on it at any one time, but there may be none at times. Each employee must work on at least one project, …

Member Avatar for goonj
0
165
Member Avatar for lexflash

Hey guys, I need to create a software which can read a barcode and I should be able to enter the value obtained from it into a database and also I need to compare them with certain values. I am comfortable working in java and would like to know how …

Member Avatar for peter_budo
0
93
Member Avatar for Xufyan

From what I gather as a Java beginner, when accessing instance members, the "this" keyword may apparently be used. see this program, [CODE]class sphere{ static final double PI=3.142; static int count=0; double radius,xcentre,ycentre,zcentre; sphere(){ xcentre=0.0; ycentre=0.0; zcentre=0.0; radius=1.0; count++; } sphere(double xcentre,double ycentre,double zcentre){ this(); // what does this mean …

Member Avatar for ruchi18
0
238
Member Avatar for Xufyan

Setter getter ..? what is this and what it does ? i searched over google but didn't find the suitable answer...!

Member Avatar for imtiyaz41
0
458
Member Avatar for k.santhan

Hai To All i want to create a siftware using java pls help me to create software thx k.santhanakrishnan SNIP

Member Avatar for kramerd
-1
39
Member Avatar for blackeyedanel

im getting an error while trying to print array contacts[i], why? any help? Thanks! :) this is my class Address where im gettingthe error: [CODE]import java.io.*; import java.util.*; public class Address{ //Declare variables String first; String last; String homeadd; String homeph; String cellnum; Scanner sc = new Scanner(System.in); public Address(String …

Member Avatar for javaAddict
0
4K
Member Avatar for severman

Hi all I have a gantt chart which i draw with JFreeChart. I want to add to this grpah a line that shows the current date. Does any 1 knows how to do it? Here is the code that i've written: [code] /* * To change this template, choose Tools …

Member Avatar for alexraa
0
186
Member Avatar for virendra_sharma

Hi friends, which are the JAVA API's available for to connect your application with LinkedIn.

Member Avatar for JamesCherrill
0
81
Member Avatar for Dean_Grobler

Hi there, I just wanted to find out if one can have a actionListener() in one .class file and then have the actionEvent() in another .class file? If not, how would I go about to get the same effect? Thanks!

Member Avatar for Dean_Grobler
0
446
Member Avatar for Xufyan

Our teacher really sux, he just wrote this down on the board but didn't explain the program :(...after a lot of search i finally understand what is try and catch but what is the meaning of [iCODE]byte b=new byte[255];[/iCODE] in this program ? and why the program is not working …

Member Avatar for JamesCherrill
0
161
Member Avatar for deleti0n

I see so many examples everywhere and none of them helped me fix these problems, so if anyone can help me I would greatly appreciate it. I have explained my errors in the red Highlighted sections in comment form.... [CODE] package lab41thestockclass; class ParkedCar { private String make; private String …

Member Avatar for javaAddict
0
111
Member Avatar for Claude2005

Hi there, I have this kind of sample table. [CODE] Name Math Science English ------------------------------- Ben 86 88 80 Peter 80 79 83 John 84 90 86 [/CODE] I want to save this result, dynamically, in a "table" in Java. I want it to have a sorting function. Some of …

Member Avatar for Claude2005
0
110
Member Avatar for Blastoise

Write a program to enter a score and a points possible for a test, computer the percent, display the percent to 1 decimal place and then display the letter grade (A – F) using a standard scale (90, 80, 70, 60) – use the if ... else if ... else …

Member Avatar for floatingDivs
0
130
Member Avatar for vij123

[CODE]<s:iterator value="listObject"> <s:component template="abc.vm"> <s:param name="text" value="listKey" /> <s:param name="prefix" value="listIndex" /> </s:component> </s:iterator>[/CODE] listKey is keys in a list. i am using iterator to traverse the list. i want to put here internationalization concept.so that when i write key of list then it find its associated values in a …

0
57
Member Avatar for lena13

2. Create a class Reals for performing integer arithmetic on real numbers. Each real number has a whole part and a decimal part; your class should contain data components representing both parts as integers and should contain methods to do the following: a. Default constructor b. set the two components …

Member Avatar for Xufyan
0
64
Member Avatar for Born2Bgeek

Anyone can to help me solve my java problem? I want 2 shapes to move at the same time when mouse dragged occurs. For example 2 objects name hat and face are created then when I mouseDragged face both face and hat will move together, but when I dragged hat …

Member Avatar for JamesCherrill
0
124
Member Avatar for rizla777

hey im just having a bit of a problem on reading input from a text file. I know that it is probably something simple but I keep overthinking it. Here is what I am trying to do: I'm trying to read in a line of text that contains musical notes. …

Member Avatar for new_programmer
0
145
Member Avatar for yuvi2288

Hi, I have write the code to upload a file to database. I checked it by uploading a text document which is in my desktop and it is working and successfully uploaded to database. [CODE]File tomcat.txt has been uploaded and inserted into Database.[/CODE] But when I tried to upload an …

Member Avatar for yuvi2288
0
302
Member Avatar for tdnghia89

Hi all, I have the following problem: My server sends the string str="1 2 4 dds \n" continuously to a C++ client.Here is the java code of the server: [CODE] private class SendingThread implements Runnable{ public Socket s; public DataOutputStream oo; public ObjectInputStream oi; ////private QueryTransferObject q; boolean connected; public …

0
74
Member Avatar for Agent Cosmic

Hi, I'm a beginner in the J2EE field. I've already learnt the basics of Java programming and now I'm moving on to web development. What I want to know is if I could skip learning JSP/JSF, servlets, EJB, JPA etc if I learn Wicket, Spring and Hibernate. I'm still not …

Member Avatar for Agent Cosmic
0
115
Member Avatar for diggerman

I'm writing a program that will ask the user for input and then store it into an array until called to the output screen. here is an example of my code so far. I have no idea how to get the input to store in the array. import java.util.Scanner; public …

Member Avatar for diggerman
0
13K
Member Avatar for kezkez

new to ArrayList and was wondering what I am doing wrong. I keep getting a null pointer exception when trying to addRecord... [CODE] import java.util.*; public class StudentDB { private List<String> studentDB; public StudentDB(String db) { List<String> studentDB = new ArrayList <String>(); studentDB.add(""); } public void addRecord(String recordAdd) { studentDB.add(recordAdd); …

Member Avatar for JamesCherrill
0
75
Member Avatar for Xufyan

I've coded this program but i am getting this error, EmployeeeMain.java:57: non-static method getdata() cannot be referenced from a s tatic context Manager.getdata(); ^ 1 error I've used the same technique in other program , it is working fine but this program is not working !! Why I am getting …

Member Avatar for JamesCherrill
0
367
Member Avatar for juice33

I have been incurring errors during compile, in which I cannot seem to figure out where the problem relies. I have a class file which is different from the java file. When running the java file im recieving the error of cannot find symbol. {note both of the files are …

Member Avatar for JamesCherrill
0
103
Member Avatar for TheKebab

I've just started learning some Java, and now I've stumbled upon what may be my biggest enemy so far, Applets. To begin with, they are inconvenient to code and and test. You have to build them in the IDE, (Using Netbeans as of now) create an external HTML which can …

0
63
Member Avatar for sciprog1

Hello Members, What is the largest integer that can be stored in Java? Thank you!!

Member Avatar for Dupron
0
136
Member Avatar for moustafa taha

hello every one this program compares loans with various interest rates [CODE] public static void main(String[] args) { Scanner input=new Scanner(System.in); //Prompt the user to enter the loan amount System.out.print("Enter the loan amount:"); int loanAmount=input.nextInt(); //Promp the user to enter the period in number of years System.out.print("Enter number of years:"); …

Member Avatar for Dupron
0
137
Member Avatar for asian_al

Im trying to make a breakout game. I cant seem get the score to show up, but I was able to get everything else working. [CODE]import javax.swing.*; import java.awt.*; import java.awt.event.*; public class PongPanel extends JPanel implements ActionListener { private Paddle paddle = new Paddle(); private PongBall ball = new …

0
62
Member Avatar for AmnGupta

Hi everyone, I'm working in netbeans IDE 6.9 for my college project work. I had made my application in such a way that, using single Desktop Pane I used to add all the JInternal Frame to it, and display one by click on the respective menuitem. For e.g. for [B]MenuItem1[/B]: …

0
46

The End.