36,051 Topics
![]() | |
hello friends, I am making a GUI for a certain fill up form using netbeans..here I need disable a "next" button until all the text fields are filled up...I have tried writing a method that which is called during every keypress event in a text box that checks whether the … | |
Hi, I am getting this error. "org.apache.commons.net.MalformedServerReplyException: Could not parse response code." after this line...ftp.connect(ftpHost.getHostName(), 22); Please help me. Thanks, Anurag | |
Hi everyone, I'm new to java. I'm getting an error cannot find symbol m_weapon when i compare char which i assigned from math.random. Thank you, [CODE]public class RPS { public static void main (String[ ] args) { Scanner console = new Scanner(System.in); //used to gather user input System.out.println("WELCOME \n\n"+ "This … | |
[CODE] import java.io.*; import java.util.*; import javax.swing.JOptionPane; public class A15 { public static void main(String[] args) { if(args.length != 1) { JOptionPane.showMessageDialog(null, "Error: Enter one command line argument."); } else { try { String[] array = LeeJungBum15.readFileReturnWords(args[0]); // read file sortAndPrintArray(array, args[0]); // sort alphabetically and print the arrays } … | |
Well i can see lot of career related questions are posted here So i thought i could contribute something for youth. with more than 5 years of Experience in above subjects I have decided to take classes. Location : Mumbai . Subjects: C Java: Java Basic. Advance Java. C#. VB … | |
I was browsing the web for examples on how to partition in Java. [URL="http://www.cs.princeton.edu/introcs/23recursion/Partition.java.html"]I've got to this website that has a detailed example about Partitioning[/URL] so I've tried to run it on my JCreator Pro. I've only got one error, but I've tried all I can do to fix it … | |
Hi there, Consider the following code, this is a little 'snipet' from one of my classes: [CODE] private void jMenu1ActionPerformed(java.awt.event.ActionEvent evt) { NewContact n = new NewContact(); } [/CODE] The method is expected to open a new Frame, where the class of the new Frame is called "NewContact". I've recently … | |
hi, Please help me. How to create an Access database using Java? THank you | |
Hi there, Let's say I have this HTML code below... [CODE] <html> <head> <title>Page 1</title> </head> <body> <form method="post" action="page2.jsp> <table> <tr> <td>John Doe</td> <td><input id="name1" name="name" type="submit" value="Edit" /></td> <tr> <tr> <td>Steve Smith</td> <td><input id="name2" name="name" type="submit" value="Edit" /></td> <tr> <tr> <td>Peter Pipper</td> <td><input id="name3" name="name" type="submit" value="Edit" /></td> … | |
Hi everyone, I just started on learning java and I have this problem I'm trying to figure out. The question is asking me to have my program read the twelve temperature values and print the month with the highest temperature. This is what I have so far: [CODE] public static … | |
any suggestions? <%@ page language="java" %> <%@ page import="trader.webservices.data.LeadDAO" %> <%@ page import="trader.aabacrm.LeadsList" %> <%@ page import="trader.webservices.data.*" %> <%@ page import="trader.webservices.presentation.Lead" %> <%@ page import="trader.webservices.data.UserInfoDAO" %> <%@ page import="trader.webservices.data.UserDataVO" %> <%@ page import="trader.webservices.data.ButtonDAO" %> <%@ page import="trader.webservices.constants.UserConstants" %> <%@ page import="trader.webservices.util.Utils" %> <%@ page import="java.math.*" %> <% RequestDispatcher dispatcher = … | |
I would like to develop a character array output that outputs ONLY a single character in each position. While my programming appear to work fine with filling all spaces with a single character or with 2 characters one each at alternating spaces, its not the same with designated position. For … | |
How would I validate a date input that looks like 01 / 23 / 10? It needs the spaces and slashes. i know how to validate the month day and year i just can not figure out how to validate the blank space and slash in Java. | |
I am trying to edit a code we were given and it's not working for me when I incorporate the scanner code Basically every place where the code says 'public static void', it says there is an illegal start of expression I HAVE to use methods for this code I … | |
Hey guys, I'm having a bit of trouble with my program. It seems that out.print(translationText) only prints out the last line in theStringBuilder translationText. It's really werid, because System.out.print(translationText) prints out everyline from the StringBuilder translationText. I added append to be true for the FileOutputStream object, but now it just … | |
Friends, I have a major problem with recursion. My question is how do you reverse a string in java by applying recursion. It's quite easy working wthout recursion by using using StringUtils.reverse, but I really really need help with recursion on this question.!!!!!!Please!!!!! | |
Hello : I have this question and I solve the half of it I wont your help in other codes.. We have do a code for every commend ... In this project you will develop many commands that are related to file operations, as in the following list (red colors): … | |
How can I change the color of the font or text? I've tried area.setFontColor, area.setColor, comic.setColor. area is the JTextArea. comic is a font. arial is a font. I have a [code]final Color red = new Color(); red = Color.red;[/code] but I don't know how to set the Font or … | |
Firstly, Hello everyone! Ok so I am going through exercises in my Java book and am having a problem with this one question. Basically, it wants a user to input a telephone number as letters capital or lower case, spaces or not... eg. Get-Loan which would be 438-5626. So the … | |
Hi, I am ajax in following concept. In jsp page have 2 div. first div contaion one dropdownlist for selection city onChange event send data to servlet and other div contain another dropdownlist for displaying cities which are come from servlet. Here problem is after selecting city through 1st dropdownlist … | |
we planned to rewrite our System in Java, Which was previously running in Stored procedure. More than 5 Applications calls the procedure which inserts and updates some set of records after the post transaction which has been done in the background. Now we planned to take the stored procedure out … | |
I need to use a rich text editor for my project, What would be the right choice to use that.and also can i get a example on that??? | |
In this program i have input name and code in super class and print it, it also print in sub class [iCODE]Manager[/iCODE] I created the object for super class to input name and code, and another object to input Manager's Data, but in the output the Name is showing null … | |
Hi guys, I'm writing a program to do several things involving getting information from the user about a book (title, author, publisher etc.) There is a Book class and then the client class BookClient. I got the program working for the user entering a single book but then I changed … | |
Hi, I am a programming newby and trying to write a Java code that does the following: - User inputs a string of choice (this part is ok) - Program reads every third character of the string and replaces with an X Any help would be appreciates. Thanks, oling | |
Hello every one i need to help me in understanding this small program ...you can approximate by using the following series ∏=4(1-1/3+1/5-1/7+1/9-1/11+1/13-.....-1/(2i-1)+1/(2i+1)) write a program that displays the value for i=10000,20000,....,and 100000 I've developed this code to solve the problem [CODE]public static void main(String[] args) { int count=1; double sum=0; … | |
Hi, Using enter key only,How to go to the next page in submit button(without clicking that button(onclick) , using the tabkey).Anyone can u help me..... Thank you | |
import java.io.*; public class Amortization { public static void main (String[] args)throws IOException { BufferedReader dataIn=new BufferedReader (new InputStreamReader (System.in)); double loanamount=0.0, interestrate=0.0, numberofyears=0.0,amortization=0.0, a=(1+interestrate),b=numberofyears ; String TextInput; System.out.print ("Input the loan amount: ") ; TextInput=dataIn.readLine () ; loanamount=Integer.parseInt (TextInput) ; TextInput=dataIn.readLine () ; System.out.print ("Input the interest rate: ") … | |
hi 2 all, I'd like to ask: how can we Concatenate elements of two dynamic arrays?? and if there is any example it'll really help. thanks in advance :) | |
Hello everyone, I am currently taking java and Im trying to learn how to write methods. I want to know learn the best way that I can learn how to read/write methods in a code. Im currently writing a code using lastindexOf. I do understand that im using this to … | |
How to enabled encryption using PHP platform so that it can sync with JAVA | |
I have several classes(all in swing). How can I put all the classes that I have create into tabbed Pane? I have 4 class: Intro in=new Intro(); Hist his=new Hist(); Product pro=new Product(); Contact con=new Contact(); [CODE]import javax.swing.JFrame; import javax.swing.JLabel; import javax.swing.JPanel; import javax.swing.JTabbedPane; public class MainControl extends JFrame { … | |
I am reading from a file. After i tokenize and assign each value to a string field i call the constructor and initialize the object. next i want to add them to an array. I have done this with a vector and all i do is [CODE=java]ObjectVec.add(obj1);[/CODE] Mind you this … | |
[CODE]public class Triangle { /*-the lengths of all sides -the perimeter -the angles at all corners -the area */ public Triangle(double xa, double ya, double xb, double yb, double xc, double yc) { x1 = xa; y1 = ya; x2 = xb; y2 = yb; x3 = xc; y3 = … | |
I would like the output to be JUST the TIME. Currently it also displays the date. How do i fix this. [code] <html> <head> <title> Start and stop a clock </title> </head> <body> <input type="text" size= "60" id="theclock" /> <script type="text/javascript"> var setIntervalID = window.setInterval("setClock()",1000); function setClock() { var now … | |
Hey Lifesavers! How can i dispose the current frame holding the combobox on item selection to navigate to the next frame. The dispose(); method does not dispose the Main class, when i select supplier item onthe combo list. how can i reolve this; sample code from the sodes is below. … | |
How do I make my array legal? It doesn't seem to like my style here. [CODE]import java.util.Scanner; public class solveQuadratic { /** * @param args */ public static void main(String[] args) { // TODO Auto-generated method stub Scanner input = new Scanner (System.in); double[] eqn = new double[2]; double[] roots … | |
Hi, I have following ajax code so here I want to help to edit the code. I have servlet name is SendInfo.java. here feaches destination cities and add into Arraylist according destination city selected by dropdownlist listFrom then that Arraylist send back to displayCity.jsp and displayed in second dorpdownlist listTo. … | |
Im trying to do this code to create a Parking ticket Simulator. This is the code. public class Parking_Ticket { private String make; private String model; private String color; private String licenseNumber; public int minutes; public class ParkedCar { private String make; private String model; private String color; private String … | |
The code for the Towers of Hanoi is here, the problem is what will the rest of the recursive calls be? [CODE] //provided in the main method that String Src="Src", Aux="Aux", Dst="Dst"; public static void solve (int diskNumber, String Src, String Aux, String Dst) { if (diskNumber ==0) return; else … | |
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, … | |
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, … | |
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 … | |
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 … | |
Setter getter ..? what is this and what it does ? i searched over google but didn't find the suitable answer...! | |
Hai To All i want to create a siftware using java pls help me to create software thx k.santhanakrishnan SNIP | |
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 … | |
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 … | |
Hi friends, which are the JAVA API's available for to connect your application with LinkedIn. | |
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! |
The End.