32,199 Topics

Member Avatar for
Member Avatar for blue6dImension

[CODE] private Node<T> addAt(Node<T> node, T value) { if (node == null) { // special case return new Node<T>(value, null); } else if (node.getNext() == null) { // other special case node.setNext(new Node<T>(value, null)); } else if (node.getstuff().getName().compareTo(value.getName()) > 0) { node.setNext(new Node<T>(value, node.getNext())); } else addAtEnd(node.getNext(), value); } return …

Member Avatar for bbman
0
179
Member Avatar for iamcreasy

Why Animal constructor is not being called by the declaration of the array? LINE 12 Isn't 10 instances of Animal class is being created with this line? [CODE]package javaapplication; class Animal { Animal() { System.out.println("Animal Constructor");} } public class Main { public static void main(String[] args) { Animal[] animal_obj = …

Member Avatar for NormR1
0
97
Member Avatar for srinivas88

Please help me..i m getting this error in vista... java.sql.SQLException:General error at sun.jdbc.odbc.createSQLException(JdbcOdbc.java:6986) at sun.jdbc.odbc.StandardError(JdbcOdbc.java:7114) at sun.jdbc.odbc.SqlExecDirect(JdbcOdbc.java:3110) at sun.jdbc.odbc.JdbcOdbcStatement.execute(JdbcOdbc.java:3110) at sun.jdbc.odbc.JdbcOdbcStatement.executeUpdate(JdbcOdbcStatement.java:288) ....etc there are 2 code pages..one is employee registration page and the details entered in this page is sent to EmpAddServlet.... [icode] import java.io.*; import java.sql.*; import javax.servlet.*; import …

Member Avatar for srinivas88
0
80
Member Avatar for roswell67

Hello, I would like to create a p2p application; File sharing / chat / etc.. and I am looking for a proper API, tutorial and documentation. I've been googling here and there for the past 6 hours trying different API's but failing.... I stumbled upon JXTA / JNMP2P ... but …

Member Avatar for gandalf123
0
139
Member Avatar for m-e-g-a-z

Hi, Im trying to match patterns to get A-F and number range 0-9 So like 9D 4EEE Not 15d heres the code i have got so far [CODE] import java.util.Scanner; import java.util.regex.Matcher; import java.util.regex.Pattern; public class sam { public static void main (String [] args){ //instantiate scanner Scanner s = …

Member Avatar for stephen84s
0
102
Member Avatar for zreed

I need to code a program for my friend and it has been giving me some difficulties. This needs to have two classes, one called Tester and another called Game. And the data in the Game class needs to be pulled to the tester class after the calculations are finished. …

Member Avatar for CrazyDieter
0
198
Member Avatar for AbhikGhosh

Hi Can anyone please help me as to how to print in java? Please tell me the basics first and then how to change the configurations.Actually I need to print in a thermal paper for issuing tickets. Can anyone please help? Thanks Abhik

Member Avatar for AbhikGhosh
0
318
Member Avatar for mikki2

hi, this is a simple program but i have no idea what the [inlinecode]args.length[/inlinecode] is for. [code] class PrintArgs { public static void main (String[] args) { for (int i = 0; i < args.length; i++) { System.out.println(args[i]); } } }[/code] i added a few more lines(below) to the code …

Member Avatar for masijade
0
10K
Member Avatar for fankoff

Hi guys, I`m new to web-developing. Curruntly I`m battling with JSP and Databases. I `m using Eclipse as developing environment and I started receiving following error, which doesn`t tell me anythnig: HTTP Status 500 - type Exception report description The server encountered an internal error () that prevented it from …

Member Avatar for stephen84s
0
170
Member Avatar for KcNaveen
Member Avatar for joverlyanne

[ATTACH]15386[/ATTACH] Can somebody pls help. i have two frames. Frame1 contains table and frame2 for the alert setting. Frame has 2 columns. The delta and the alert. The situation is when i set the alert setting to a given value and the delta met it. the alert column (each cell) …

Member Avatar for NormR1
0
86
Member Avatar for nestensity

I have been trying to read a file, put it in an array and then find the average of the integers in the array. However I am unsuccessful with putting an integer in each slot of an array. When I print qa1[0] I get a long chain of 30 but …

Member Avatar for NormR1
0
148
Member Avatar for Zhoot

Heya. I require assistance regarding one of my Java programs. As the program is rather large I'm unable to post the source. The problem, My program will not start once I try to execute the Jar file associated with the program. Platform, Netbeans IDE 6.8 Description, I've written this program, …

Member Avatar for NormR1
0
99
Member Avatar for zyaday

AudioTrack sound = audio.createAudioTrack("ringout.wav", false); is giving me the output "WARNING: Unable to locate: ringout.wav" The sound file is in the same project folder that i am using..Anyone knows what i might be doing wrong in here? Thanks a lot.

Member Avatar for NormR1
0
191
Member Avatar for kdmuk10

When i was trying to run a program from the IDE, a window pops up which has anagrams as a title and requests me to enter something under "Your Guess" slot? What is happening?

Member Avatar for NormR1
0
120
Member Avatar for walkerpbus

I hope my title says it all. I can't show you the jpg error, because the size is too large to upload (3 MB). The mix of Firefox, Windows 7, Zonealarm. I am researching Firefox in a Firefox forum. All I know is the Combo of the same Firefox, no …

Member Avatar for walkerpbus
0
261
Member Avatar for ttboy04

Hello, When random generates an output, it cannot show duplicate strings. So for example the output I am getting (randomly) is, "Freddy, Freddy, Jane" when it should be "Freddy, Jane". I have to hardore so I cannot use Sets or ArrayList, Contains or for anything like that. Also no Stringbuilder. …

Member Avatar for aspire1
0
136
Member Avatar for anjkris07

hi.. i'm still new to java and i have a project to work on regarding card games. I want to shuffle the deck but i just can't get it.Shuffling the deck must be alternate each element. I don't know if i'm doing the right thing. I keep getting a " …

Member Avatar for anjkris07
0
207
Member Avatar for redZERO

I know that i might be jumping straight into the 'deep end', however I want to make a program which accesses a file (.txt for example) over the network. For example, you type in the IP Address of the computer where the file is stored, and the program reads from …

Member Avatar for NormR1
0
158
Member Avatar for vijayindia

plz reply to my web id my web id is <EMAIL SNIPPED> plzhelp me[code]import java.io.*; import java.applet.*; import java.awt.*; class crystal extends Applet { private crystalGrid crystal; private Button reset, stop, go, moreRows, fewerRows, moreCols, fewerCols; public void init() { reset = new Button("Randomize"); add(reset); stop = new Button("Stop"); add(stop); …

Member Avatar for CrazyDieter
0
105
Member Avatar for gokavepr

Hi, i wanted a code in java where we can export the text file with delimiters to an excel sheet

Member Avatar for stephen84s
0
36
Member Avatar for nestensity

I'm trying to create a program that prompts the user to input the amount of students and their score and then prints it out. However im stuck at slots.get(i).inputData(); as i get [CODE]Exception in thread "main" java.lang.Error: Unresolved compilation problem: Cannot invoke inputData() on the primitive type int at GradeBook.main(GradeBook.java:52)[/CODE] …

Member Avatar for stephen84s
0
127
Member Avatar for jiten_raulo

Hi Experts, I want to calculate age, i.e. user enter the date of birth and the output would be the age. I guess I should use GregorianCalendar. The logic is subtracting the user date from current date. But how? Can any one have any idea…………… Thanks in advance JIten

Member Avatar for stephen84s
0
92
Member Avatar for reebeca

Hi all, I have developed a java web application which sends sms to many people at once, Now I wanted to get the delivery status of the sms sent. Can Any body help me to do this. Rebeca

Member Avatar for stephen84s
0
90
Member Avatar for rukshilag

i need Given a set of numbers on the command line (partition an array) It should check whether a solution exists and if so print the two sets upto now the code i have seems to parttion each integer, what i need is for it to partition the array as a whole, for example lets take the array[1,2,3] this can be divided as [1,2] and [3], we can see that …

Member Avatar for thamilvaanan
0
573
Member Avatar for MPQC

Alright. So here's what I've currently got. Basically, I've got an array of numbers - any amount. My current code counts up the frequency of each number, then prints out the one that is the largest, and it works perfectly. But the problem is, I need to make it be …

Member Avatar for MPQC
0
2K
Member Avatar for ushanaveen

hello sir.......i am studying MCA final year now i would like learn java so suggest me how to learn java means core and advance java .........

Member Avatar for Ezzaral
0
42
Member Avatar for pricey3000

I am trying to implement a toArray() method in my PriorityQueue. The PriorityQueue returns an array of Objects, but I want to do is have an array of the original type of objects which in this case is Job (which is marked by the 'T1'. The following is the toArray() …

Member Avatar for pricey3000
0
496
Member Avatar for Umar Ali

Man!! I'm freaked out, I'm not able to do it Actually I add dataValues 2d array and colNames array in new created jtable but it doesn't work. Don't know why :S I also wanted to add button before the table but that's doesn't work even... PLease help me... [CODE] /* …

Member Avatar for NormR1
0
102
Member Avatar for stmartin

Hello! I am new user of this forum, and I want to ask you for ideas for finding the probability of winning in pre-flop, post-flop etc... For example, there are 3 players on the table (2 opponents). A (spade) A(heart) (1st opponent's cards) A (club) 8 (club) (your cards) 7 …

Member Avatar for NormR1
0
196

The End.