32,199 Topics

Member Avatar for
Member Avatar for vladacmba

Hy everyone, Thank you for taking your time to explaind me this, I very thankful for all of you. I'm been searchin what kind of a Script is it - so foergive me if I'm at wrong post - but no luck. Take a look at this 2 website examples …

Member Avatar for javaAddict
0
87
Member Avatar for TigerGirl

How would you draw a expression tree that is (a-2/(5 * b) plus 3) * (2 * d)? I am really confused on the first parenthesis. Thank you for your help.

Member Avatar for TigerGirl
0
62
Member Avatar for TigerGirl

Hello I am trying to read a node that will find the longest word in a tree. So, my method is a public static int word(Node d) So how would I have to find the length of that node? Would I just use the string that was made in the …

0
108
Member Avatar for Sandar Khin

I have a program. Here import java.awt.*; import java.awt.event.*; import javax.swing.*; class MarqueeTest { public static void main(String[] args) { MyFrame frame = new MyFrame(); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.setVisible(true); } } class MyFrame extends JFrame implements ActionListener { private ActionListener listener; private Timer t1; public MyFrame() { Dimension d = Toolkit.getDefaultToolkit().getScreenSize(); setSize(d.width,d.height); …

Member Avatar for Sandar Khin
0
172
Member Avatar for prelyptica

I an trying to write a few java classes, which I wrote successfully, but when I am tryin to test it I get some weird errors and I cant figure out why, so i'd be very grateful for your expertise. The code for the GCD class is: [code] public class …

Member Avatar for thines01
0
191
Member Avatar for ryno365

Hey DW. Working on a nice poker application and need some help. Right now I'm trying to go through two arraylists, one of chars and one of sorted ints (representing the suites, and numbers of the cards) and delete duplicating numbs (and the char/suite counterpart in the other array). In …

Member Avatar for ryno365
0
98
Member Avatar for shroomiin

hello everyone, i am trying to write a code that displays a table with 75 years. each year has to display the world population and the projected population for the following years after that by multiplying the current population by the yearly growth (1.17) but i am running into some …

Member Avatar for Ezzaral
0
129
Member Avatar for junglee

i`m making Quiz program which asking State and you answer capital. here is code import java.util.*; import java.awt.*; import java.applet.Applet; import java.awt.event.*; import java.io.*; import java.util.Random; public class Quiz extends Applet { private String textfile = null; private TextPanel text_p = null; private Vector question = new Vector(); private Vector …

Member Avatar for quuba
0
297
Member Avatar for YingKang

the program draws lines, but every time I draw a new line, the previous one disappears. How can I let it show all the lines drawn? I know my problem is in the array, but how to fix it? thanks for help [code] import javax.swing.JPanel; import java.awt.*; import java.awt.event.*; import …

Member Avatar for YingKang
0
817
Member Avatar for whiteyoh

Hi all, On compiling, i get no errors at all, the data is taken, but when checking the database, a record is made, but it is NULL. What have i missed? [code] /* * To change this template, choose Tools | Templates * and open the template in the editor. …

Member Avatar for Ezzaral
0
160
Member Avatar for kilermage

I run the program, from what I see the game runs fine. Then when I click on the object that suppose to send a dialogue, it disconnects me and throws this error in the run.batch window. [CODE]Exception in thread "main" java.lang.NullPointerException at NPCDialogue.UpdateNPCChat(NPCDialogue.java:18) at client.process(client.java:8471) at PlayerHandler.process(PlayerHandler.java:137) at server.main(server.java:55)[/CODE] Here …

Member Avatar for ejosiah
0
149
Member Avatar for karthik.c

hi guys im tryin to do a java client / c++ server socket program .in the java client program i serialize the object and pass them over socket to c++ server.now when im gettin them in c++,im not able to deserialize it properly as i tried for binary serialization since …

Member Avatar for ejosiah
0
583
Member Avatar for whiteyoh

Hi all, this is a bit of a follow on from a previous post, but slightly different so thought a new post would be best. i want to pass my scanner variables into an object. the following is the last scanner (Added as example), followed by the creation of a …

Member Avatar for whiteyoh
0
116
Member Avatar for whiteyoh

Hi all, I have a constructor with 2 numbers both set as longs however in my driver class, it is showing as an error, even after casting the already longs to a long again. This is constructor [code]public Personal(String forename, String surname, long dob, String add1, String add2, String county, …

Member Avatar for whiteyoh
0
102
Member Avatar for calcucool

i need to write a method that in my program student object for the student class that validates it's own data. background on student class: it's a program that ask for a name of a student and 3 test scores and print the highest , the lowest and the average. …

Member Avatar for javaAddict
0
103
Member Avatar for shroomiin

Hey everyone. I have to write a program that estimates the value of mathematical constant e by using the following formula and i have to allow the user to enter the amount of terms to calculate. the only problem is i dont really know how to get started with this. …

Member Avatar for javaAddict
0
101
Member Avatar for verilu

So, I'm stuck trying to figure out how to move the object. I am using the keyboard as a call to Key Event to move the object. Right now, it isn't moving. I'm pretty sure that this is correct. [CODE]import java.awt.Color; import javax.swing.*; import java.awt.Graphics; import java.awt.Image; import java.applet.Applet; import …

Member Avatar for nambro
0
107
Member Avatar for bennettgirl99

So I have spent some time on this.... Write a program named TrafficLightcontroller Program should have a main method Construct three TrafficLight objects named:light1,light2,light3 Repeatedly print a menu that allows a user to type in responses and control the three lights. Menu: Select traffic light (0 to quit): 1 1)change …

Member Avatar for quuba
0
155
Member Avatar for asong

have a java program that have evaluate thefunction,calculate the derivative and roots haw can i demonstrate numerical methods to solve the runge kutta method. This ma functiuon package Iterative.Newton; import java.io.*; import java.text.DecimalFormat; public class Newtonlastest { public static void main(String[] args) throws Exception{ BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); …

Member Avatar for quuba
0
670
Member Avatar for mamanbadry

Hi, I am a new user of Fedora. I should work with an open source package which works in Linux. Therefore, I installed Fedora 11. At the moment, I must install Apache Ant to continue. However, I am confused! I don’t know how. I appreciate if you tell me the …

0
102
Member Avatar for sridhar123
Member Avatar for sridhar123
Member Avatar for skiplatte

Hi, I have used Tokenizer to split a user input string into tokens and retained the delimiters (R and K). Is there any way to combine each delimiter with it's preceding token to create a result string? eg change tokens FGADA and R into one string FGADAR which I can …

0
52
Member Avatar for Java-newb

I am a student really struggling with Java and needless to say, I am pretty isolated from anyone who gives a care enough to help me, I am on my 8th week and really struggling with GUI's I have some code written, but the gui will not display, I am …

Member Avatar for Java-newb
0
170
Member Avatar for hajjo

anyone knows how? if its empty or null? events.get(x).getOccurredDate() == null thats not working. neither events.get(x).getOccurredDate().equals("")

Member Avatar for masijade
0
93
Member Avatar for Mareshal

I have a program with multiple JAR files. I need to edit only 1 class in only 1 jar file. I've decompiled them to *.java files, edited, but I can't recompile them. I tried javac name.class but I get a ton of errors. any help?

Member Avatar for Mareshal
-1
209
Member Avatar for Maverick

I am finishing up writing an extensive C/C++ program and am in dire need of completing these 4 short JAVA programs. Any help would be appreciated GREATLY! (I missed a few days of lecture and am extremely behind in this class.. :sad: EDIT: actually just helping me with one or …

Member Avatar for javaAddict
0
642
Member Avatar for Holmez85

Hi, im pretty new to java. Im attending a programming class at a college in norway. I have only been programing for 3 months. My question is, how can i for example print all items or a selected item from the games archive(so i get it in a new window …

0
81
Member Avatar for bigginger

I'm new in programming and need to validate this class email. Anybody can help? public class Email { private String email; public Email() { email = ""; } public Email(String emailAddress) { this.email = emailAddress; } public String getEmail() { return email; } public void setEmail(String email) { this.email = …

Member Avatar for bigginger
0
102
Member Avatar for ashokp27

We are currently using MSJVM for JVM, and there are some class files for tuxedo application.... Now as MS as has stop MSJVM support we want to move form MSJVM to SUN JVM. Please some one guide us, how to use existing class in sun java

0
40

The End.