32,199 Topics

Member Avatar for
Member Avatar for AngelOfRock

Hi guys, i'm trying to program a simple Tic-Tac-Toe game with extern Buttons. When i'm compiling the Code there's no mistake, when i press Button1 every thing ok, but on the most other Buttons a mistake is shown up : Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at grafik.Zeichenfenster.farbeAufloesen(Zeichenfenster.java:330) at grafik.Zeichenfenster.zeichnen(Zeichenfenster.java:276) at …

Member Avatar for JamesCherrill
0
799
Member Avatar for kkcaddy

import java.util.*; public class EmployeeTest { public static void main (String[] args) { Employee[] staff = new Employee[3]; staff[0] = new Employee("Carl Cracker", 75000, 1987, 12, 15); staff[1] = new Employee("Harry Hacker", 50000, 1989, 10, 1); staff[2] = new Employee("Tony Tester", 40000, 1990, 3, 15); for(Employee e : staff) e.raiseSalary(5); …

Member Avatar for NormR1
0
190
Member Avatar for Dark_Omen

Is there a way to convert a double to string. I tried to do it like this x.toString() and it didnt work as well as implicitly converting it.

Member Avatar for JamesCherrill
0
474
Member Avatar for 47pirates

Why the method of the following class is getting invoked several times even if the condition is false.Please help me with my code... public class PRDDayBook { int remX; public PRDDayBook(int x) { remX = x; PrinterJob pj = PrinterJob.getPrinterJob(); PageFormat pf = pj.defaultPage(); Paper paper = new Paper(); double …

Member Avatar for 47pirates
0
100
Member Avatar for annu.mait

how to get refrence of notepad what we havae created using runtime class.,,as i want to write data on that notepad what i m reading from another notepad..can i have an example.?

Member Avatar for NormR1
0
29
Member Avatar for zeusprog

Please how do I convert a string of hexidecimals “10B71356C845FB08E04951AAA2FF9F49” to integer? I tried using getBytes then Integer.valueOf but I got 32 integers instead of 16. Any help would be greatly appreciated. Thank you.

Member Avatar for zeusprog
0
229
Member Avatar for sageetam

hi... I want to write a program which will find out the complexity of a given program or code given as a input through file...... plz help me.....

Member Avatar for JamesCherrill
0
31
Member Avatar for kkcaddy

> Quoted Text Here i got this code from a book i am practicing with and when i try to compile it returns the following error EmployeeTest.java:30: incompactible types found : java.util.Date required: Date hireDay = calendar.getTime(); please how do i debug it import java.util.*; public class EmployeeTest { public …

Member Avatar for vinnitro
0
206
Member Avatar for john.damilare1
Member Avatar for hszforu

I am not able to figure out what's wrong with the following code: Is it a rule to create objects in class that contains main method and then use this object to access the methods? I did exactly reverse in the following code and i am not able to compile …

Member Avatar for hszforu
0
234
Member Avatar for Deepika Deepi

hi all, This is my first post in this site. I have a sentence like this String input = "India/world is my Country and it is in Asia/in world"; I want to remove the word followed by the / and get the result of otheres. Output **India is my Country …

Member Avatar for JamesCherrill
0
215
Member Avatar for LoyalOne2

Hi I have a program that I am to write that is suppose to read from a text file. I am suppose to assume no more than 100 item and terminate after by -1. have to read and store the data. I have to write a method to print the …

Member Avatar for Starstreak
0
147
Member Avatar for rostand.lagarde

Hi There, please guyz, can I please have The code that generates student's code using the first letters of their Names.

Member Avatar for JamesCherrill
0
30
Member Avatar for borchu

Hello everyone, I progress step by step my problem, one step is passed -now I can send string datas -text messages- here another step is I want to record some audio sounds by using microphone in first android emulator assume phone1 and send to second android emulator-phone2-. I found whole …

Member Avatar for borchu
0
9K
Member Avatar for krovi
Member Avatar for jalpesh_007
0
61
Member Avatar for pinsickle

I'm trying to learn Java, pretty easy so far as my previous experiance is with C/C++. I was just curious how to call java classes from different files. That way I don't have to have main as well as all of my classes crammed into one file. I'm sure the …

Member Avatar for dimapoter
0
9K
Member Avatar for zeusprog

Please I am relatively new to Java and would really appreciate your help. Can anyone please tell me what I am doing wrong. I'm trying to send a string to an oracle and save it's output. My program just hangs when I get to this block of code. try { …

Member Avatar for zeusprog
0
155
Member Avatar for LoyalOne2

I have to write a program in java to compute the standard deviation and the mean. I am also to write a test program that will prompt the user to enter 10 numbers and display the mean and standard deviation. I have stared on the program and so far this …

Member Avatar for LoyalOne2
0
2K
Member Avatar for venkateshyeluri

Hi, Im working on a html5 parallax site. I have a problem with the javascript, that it is not detecting the screen resoultion thought I have right css files in my folder. My js detects for one type of screen resolution but it is not detecting the remaining screen types …

Member Avatar for JameB
0
332
Member Avatar for admiralis

Hi this is a PSEUDOCODE. I don't know if is the right place to ask. Can someone takes a look of my pseudocode? I am not sure if I understood the assignment. Thanks! Equinox Nursery maintains records about all the plants it has in stock. The nursery needs a program …

Member Avatar for JamesCherrill
0
194
Member Avatar for royaan.khan

I Want to draw a grid over image that is set or loaded on to a JLabel ,,,,,, when i draw a Grid it push the image forward on JLabel and take place of that image on JLabel ,,,

Member Avatar for JamesCherrill
0
38
Member Avatar for noktasizvirgul

I initialize the selenium like [CODE]public void setUp() throws Exception { setUp("http://localhost/", "*firefox"); } [/CODE] and I write my test in the method like [CODE]public void testUntitled() throws Exception { boo(); foo(); }[/CODE] But it gives error like [CODE]java.lang.RuntimeException: Could not start Selenium session: Failed to start new browser session: …

Member Avatar for Grace Gao
0
866
Member Avatar for admiralis

Hi I am new in this forum. I need some help with this code and is for my intro to programming class. I did it following a pseudocode I found in other website but I am totally confused now. It is not working. Do nothing. Thanks This is the assigment …

Member Avatar for admiralis
0
274
Member Avatar for jalpesh_007

I have one CSV file containing so many attribute but i want max and min values of particular specified columns. I have write following code for finding minimum value from each specified column,but i got only minimum of last column, not all column. In dataset.csv file contains 25,185,98,65 15,-20,6,95 17,20005,63,-78 …

Member Avatar for Taywin
0
3K
Member Avatar for jalpesh_007

Dear all, I have one question arise in my mind while i am making my project. I have one column "AGE" is there.So many values are stored in this column ranging from 0-100. I also have find frequency of each age like age=5 comes how many times in my column …

Member Avatar for Taywin
1
120
Member Avatar for dantheman4

Hi I am just starting to learn about java.I am trying to calculate BMI of an individual using the JOptionPane.showInputDialog method who I am asking to enter 4 things first name,last name,height in inches and weight in pounds. I want to show the BMI using JOptionPane.showMessageDialog method showing their full …

Member Avatar for NormR1
0
1K
Member Avatar for ihiroshi30

hi my name is hiroshi.. im new with java programming.. my prof gave us an assignment to make a calendar.. i don't know what to do.. my head going crazy i dont know what is wrong with my code.. please help me T_T your big help is much appreciated.. import …

Member Avatar for JamesCherrill
0
237
Member Avatar for student_2012

De Morgan’s Laws. We have discussed the logical operators &&, ||, ^ and !. De Morgan’s Laws can sometimes make it more convenient for us to express a logical expression. These laws state that the expression !(condition1 && condition2) is logically equivalent to the expression (!condition1 || !condition2). Also, the …

Member Avatar for NormR1
0
422
Member Avatar for pocix

i need help with building the controller by using MVC pattern view 1 import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import javax.swing.*; public class BankView { JFrame frame; JPanel one, two; BankSaving saving = new BankSaving(); BankCurrent current = new BankCurrent(); BankView(){ frame = new JFrame(); one = new JPanel(); JButton b1 = …

Member Avatar for pocix
0
445
Member Avatar for jalpesh_007

i have write a code for making a string that is being read from CSV file. i want to make a string from particular location of each and every line. i have attached a code what i have done.but i want it as it for any number of location. In …

Member Avatar for jalpesh_007
0
294

The End.