32,199 Topics

Member Avatar for
Member Avatar for BleepyE

Im trying to figure out why this simple piece of code isnt working. The aim is for the user to enter a word and then the application echos the word back to them. If the word is equal to 'done' then the application prints 'Complete'. [CODE]import java.util.*; public class word …

Member Avatar for BleepyE
0
113
Member Avatar for tqmd1

Dear Experts I want textbox1 to accept only numeric data as 55,65,698.00 Is there any easy way to validate textbox1 with javascript? Please help

Member Avatar for JamesCherrill
0
140
Member Avatar for ajwhite4

I am stumped on how to go about coding my checkAttempt() method. Its supposed to check to see if the current row in int board is equal to int code as well as check each position and log how many numbers are in the correct position as well as present …

Member Avatar for hiddepolen
0
1K
Member Avatar for Jedilance

[B]here is the problem:[/B] -user enters "degree" and a "threshold" value -degree is converted to radians(with a static method) -computing the approximation as long as the absolute value of the series element is greater than the threshold [COLOR="Red"]series:[/COLOR] i.imgur.com/GRsIP.png -Error is computed as absolute difference of approximation and the value …

Member Avatar for Jedilance
0
153
Member Avatar for Panathinaikos22

Hello, i have eclipse and in my laptop and i have a little problem when i call functions, example: when i create an button and i want to change size... [CODE]Button b = new Button();[/CODE] b.setSize([COLOR="Red"]arg0,arg1[/COLOR]); this is my problem, why eclipse show me as arg0, arg1 and not like …

Member Avatar for Panathinaikos22
0
99
Member Avatar for maawali

In the banking application, get customer Id, customer name and initial amount of 500. For further transaction and balance maintaining, the customer will enter amount and type of transaction. There are two types of transaction Deposit and Withdrawal for example: • If transaction type is Deposit Enter Amount to deposit: …

Member Avatar for JamesCherrill
-1
62
Member Avatar for alorand

I'm trying to read data from a text file that looks something like [CODE] United States 155981460 50.28 Indonesia 40829720 16.8 India 38045000 3.24 [/CODE] I need to add all the numbers after each country together. I also need to which country has the highest number in the third line …

Member Avatar for NormR1
0
247
Member Avatar for Joey_Brown

Hello Im having some new Java problems, while trying to export my project to a JAR file in Eclipse. When I run it from the IDE its OK, all roses and bourbon, but I get hit over the head this when I run it from cmd : [CODE] C:\Users\Joey\Desktop>java -jar …

Member Avatar for NormR1
0
171
Member Avatar for ali11

need help to add main class to test this program. [CODE]public class Rational { private int num; private int den; public Rational ( ) { num = 0; den = 1; } public Rational (int a, int B) { num = a; den = b; simplify ( ); } private …

Member Avatar for jwenting
0
196
Member Avatar for SomeNewGuy

[CODE]<%-- Document : index Created on : Dec 5, 2011, 10:44:50 PM Author : Orange --%> <%@page contentType="text/html" pageEncoding="UTF-8"%> <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>The Collection</title> </head> <body> <center> <%------------------Search-------------------------%> <form method="post" action="search.jsp">Please select the search parameter you want: <select name="SearchDB"> <option>Please select one</option> <option>Collectable</option> <option>Item Owned</option> …

0
90
Member Avatar for warlord902

I'm looking for a good book about Servlets and JSP for beginners. So far, the only book I know and have read is Head First Servlets & JSP, but it's focused more on the SCWCD exam rather than the specifics on building stuff. I'm looking for a book that has …

Member Avatar for warlord902
0
177
Member Avatar for spades0001

Hey guys! I created a dialog box the prompts the user to input a name. I want that name to be displayed in a textarea. How do I accomplish this? And is displaying it in a textarea right or do I use something else like say a textpane? Here's my …

Member Avatar for JamesCherrill
0
173
Member Avatar for gourav1

please tell me that as i have learnt core java and i want to give SCJP which is coming in january? what exactly this exam is all about? how should i prepare for it? what is its value if i will pass this exam? please me all info about this. …

Member Avatar for stultuske
0
157
Member Avatar for rotten69

Hey everyone, I'm wondering why I can't print the values that are in the array. I'm passing an array to the method below and trying to print the result.. the compiler says that "ArrayIndexOutOfBoundsException" What's the problem really? [code] public static int[] treble(int[] nums){ for (int i=0; i <= nums.length; …

Member Avatar for stultuske
0
153
Member Avatar for riahc3

As some of you have read, Ive been working with JNI for these days. Ive found that JNA may be easier to manage and also allows some other things. I have this very simple program: The .cpp: [code] #include <stdio.h> #include "PruebasDeJNA.h" int suma(int a,int b) { return a+b; } …

Member Avatar for riahc3
0
153
Member Avatar for Blahthing

im having trouble closing this class, ive been trying for 2 hours Its a huge collection of ifs [ICODE] package net.minecraft.src; import java.util.Random; import java.util.*; public class ItemTestItem extends Item { public int TimesShot; public ItemTestItem(int i) { super(i); maxStackSize = 1; setMaxDamage(50); } public void onUpdate(ItemStack itemstack, World world, …

Member Avatar for hiddepolen
0
132
Member Avatar for asif49

private ArrayList<Employee> employee = new ArrayList<Employee>(); How do I write this attribute on a UML diagram?

Member Avatar for StephNicolaou
0
95
Member Avatar for beshoo

Dear all . :) i have 2 classes which generate a key look like this one : Lg+jExclU6WUbd2bKF1OZay1A4vzMHff8Di2TLoBnTwvtmdzZQrq4JErJCJzurKlbNrIBs05q4wf5uTirLVREQ== the 1st class : import java.math.BigInteger; import java.security.KeyFactory; import java.security.NoSuchAlgorithmException; import java.security.PublicKey; import java.security.spec.RSAPublicKeySpec; import javax.crypto.Cipher; import javax.crypto.NoSuchPaddingException; public final class c { public static String a(String paramString) { RSAPublicKeySpec localRSAPublicKeySpec = …

Member Avatar for stultuske
0
2K
Member Avatar for dsoto

Using the file of sunset data, write a program using graphics that shows the sunset and sunrise. When I run the program, it says java.lang.NullPointerException. I want to know where I put the sunset data file. I am using eclipse. Here is my program: [CODE] import javax.swing.*; import java.io.*; import …

Member Avatar for stultuske
0
270
Member Avatar for ibthevivin

I'm wondering if there is a way to simplify this program. I feel like I wasted a lot of time on all the ternary codes at the bottom for labeling "bill" for the three values (ten$, five$, and one$). Also for deriving the values for q,d,n, and p I feel …

Member Avatar for JamesCherrill
0
138
Member Avatar for Majestics

I am creating a project, which one start copy itself to any drive and stop execution and run other file which was copied.... No progress yet... Has any one done similar type of project before.... Need a bit for starting guidance.... Thank you.

Member Avatar for mKorbel
0
108
Member Avatar for umsungun

I'm trying to create a word game in which a player must guess a secret word. Initially the secret word it showed as a series of underline characters corresponding to the length of the word to guess example: “pig” - - - When a letter entered by the player is …

Member Avatar for peter_budo
-3
189
Member Avatar for kumaresen

i ahve to write a java program using method...the program uses a method to calculate the total cost to rent the business area.then it prints the result... the rent for 100 square feet tent is 100 per day...the user has o key in the square feet needed and the rent …

Member Avatar for peter_budo
-1
211
Member Avatar for s_j_s

Hi all, I am looking for a shareware source code for a mortgage calculator to place on a WordPress website? Greatly appreciate your help. Thank you!!!

Member Avatar for jwenting
0
310
Member Avatar for pro_learner

I have developed a Java GUI App.I want to connect that with mysql.I have already connected a seperate java file with mysql.That java class is also in the same package in my Netbeans project.I want to know is it possible connect DB by using that seperate java class?

Member Avatar for pro_learner
0
146
Member Avatar for oldezwe

once I have requested my result set from my server, how do i store it as the variable that I want it to be? EX. [CODE]ResultSet rs2 = st.executeQuery("select userIDnum from userInfo where username = '"+username+"'");[/CODE] how do i then save userIDnum as an integer to use in my program?

Member Avatar for anand01
0
44
Member Avatar for javabeg123

i have to create a Weight application that prompts the user for their gender (male or female) and their height and then determines their ideal body weight. The following formula is used to approximate ideal body weight: men: Ideal Body Weight (in kilograms) = 60+ 2.3 kg per inch over …

Member Avatar for IcantC
0
180
Member Avatar for badnack

hi at all, i'm wirting a program (a chat) to connect two process via socket using ssl connection. In order to make portable this chat i've written a single body formed by two threads, the first has a client behaviour (users can connect to other users) and the second thread …

Member Avatar for badnack
0
293
Member Avatar for tomay

Hi guys, I'm trying to create a spotify like program for windows. I know a little about programming, I'm just not sure where to start with this project. Any advice would be greatly appreciated. Thanks

Member Avatar for NormR1
0
32
Member Avatar for asif49

One of my classes have a large amount of the logic and functionality of the program inside it. Let's call it Class A. This uses other classes, even an interface class and utilizes its methods too. Does this mean that every class has a dotted line arrow(dependency) arrow pointing TOWARDS …

Member Avatar for asif49
0
46

The End.