36,051 Topics

Member Avatar for
Member Avatar for rizillion

Hi!, I have created a user inteface named "helpGUI". This user interface contains a JTextArea. I also have created a text file named "help.txt". I need to show the "help.txt" file in the JTextArea. As I'm new to JAVA I have no idea how to do this. Given below is …

Member Avatar for peter_budo
0
751
Member Avatar for akulkarni

i wish to print sll the combinations of digits of a number eg 123 gives 321 132 231 132.... [code] class numbers { public static void main(String args[]) { int num=123; int x=num%10; int y=num/10; int z=100*x+y; System.out.println(z); } } [/code] this is all my brain is letting me to …

Member Avatar for JamesCherrill
0
114
Member Avatar for sotvisal

import java.util.*; class Array { Scanner in() { return new Scanner(System.in); } void out(String n) { System.out.print(n); } int[] getarray(int n) { int a[]=new int[n]; for(int i=0;i<a.length;i++) { out("Enter A["+i+"]: "); a[i]=in().nextInt(); } return a; } void showarray(int[] a) { for(int c:a) out("Array: " +c); out("\n"); } void sortinc(int[] a,int …

Member Avatar for zeeven
0
118
Member Avatar for akulkarni

[code] i want a program which asks the user to type the password. If he goes wrong three times exit.this is my code import java.io.*; class password1 { public static void main(String args[])throws Exception { String pass="samarth"; boolean flag=false; BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); String [] password=new String[20]; int i; for(i=0;i<3;i++) …

Member Avatar for tux4life
0
294
Member Avatar for rizillion

Hi! I have added an action listener for a button. When i click this button it should go to the second tab in the tabbed pane which i have created. I have created two tabs as follows: [CODE] tab.addTab("Change Password", panel1); tab.addTab("Add new User", panel2); [/CODE] and the action listener …

Member Avatar for llemes4011
0
2K
Member Avatar for Tmanchester

Howdy, I am quite unskilled on UI but have been tasked with looking at behavioral problems on our site. It has been observed that the app acts differently when a user clicks on a submit button with a mouse versus tabbing to it and the pressing Enter on the keyboard. …

Member Avatar for Airshow
0
114
Member Avatar for lakshay

Hi JavaExperts I have done few program in Java using Bit wise AND OR operator... But Not getting the proper output or May be I am doing something wrong Can any body explain why I am getting output class Bit { public static void main(String args[]) { System.out.println(010|4); } } …

Member Avatar for llemes4011
0
111
Member Avatar for memegha123

hi! this is what i m trying to do i m trying to display a form which has a drop down menu n a table displaying some basic data....now i want once user selects an item i want the form to submit to itself with the selected item as parameter..n …

Member Avatar for javaAddict
0
151
Member Avatar for gshockneo

Hi, I am really struggling with this problem. For ex. I have a login jsp page . After user logs in , I store their username and password in session object in next page. Now if I want more than 1 user to abe able to login from same browser. …

Member Avatar for gshockneo
0
997
Member Avatar for mimsc

Hey Fellas...Im getting this error on a "select box"...im trying to parse some info: PWC6197: An error occurred at line: 88 in the jsp file: /jsp/cpanel/HomeSellerList.jsp PWC6199: Generated servlet error: string:///HomeSellerList_jsp.java:147: cannot find symbol symbol : method indexOf(java.lang.String) location: class java.lang.Object PWC6197: An error occurred at line: 88 in the …

Member Avatar for hkansal
0
90
Member Avatar for George2

Hello everyone, I am looking for some approaches which can prevent my .class file being decompiled. My questions are, - I have heard that there is an approach called "obfuscated", I am wondering whether it is the best approach which meets my goal. If it is, where is the best …

Member Avatar for masijade
0
146
Member Avatar for manfosys

i wrote a code for download image from the website using URL class in java.The code is working fine.But the problem is after some time it shows- java.net.ConnectException:Connection timed out .Here i didnt use any proxy server and firewall.some sites gave soln as like change proxy settings or it is …

Member Avatar for manfosys
0
113
Member Avatar for sotvisal

import javax.swing.*; class Customer { int id,rate,pre,cur; String name,sex; String read(String n) { return JOptionPane.showInputDialog(n); } int readInt(String n) { return Integer.parseInt(read(n)); } void out(String n) { JOptionPane.showMessageDialog(null,n); } public Customer() { id=1; name="Visal"; sex="Male"; pre=13214; cur=13362; rate=720; } int consumption(int pre,int cur) { return(cur-pre); } int payment(int rate) { …

Member Avatar for kvprajapati
0
142
Member Avatar for vinaykumar1690

I recently downloaded the Eclipse(Ganymede) EE editor.I also downloaded the web application server community(WASCE 2.1) edition from IBM. I started off with a simple HelloWorld web application.i just displayed the msg in the default index.jsp page. When I deploy the application on the WASCE server the web browser is showing …

Member Avatar for sillyboy
0
429
Member Avatar for llemes4011

Hi. I have a Vector of Vectors that I need to rotate 90 degrees clockwise and 90 degrees counter-clockwise. I got it to rotate Clockwise, but whatever I try, I can't get it to rotate counter clock-wise. The 2D Vector is not always going to be a square. It will …

Member Avatar for llemes4011
0
302
Member Avatar for akulkarni

[code] i read that a method that is is using throws clause must be mentioned in the try and catch block.So when we use "throws IOException" in the following program why dont we use try and catch import java.io.*; class testthrows { public static void main(String args[]) //throws IOException { …

Member Avatar for akulkarni
0
110
Member Avatar for ndoe

anybody help me!! i have one tombol that tombol will be used to evaluate the explain!! i have some question with answer choise(a,b or c) with that tombol i want know if my answer true or false!thanks can you show me with a simple database and last question from me …

Member Avatar for peter_budo
0
122
Member Avatar for jooa

Hi, I am trying to write some code to insert coordinates which are taken from the mouseClick position and then added to a 2D array. The user should click 6 positions on a panel and these positions should be stored in a 2D array. I hope you can help. Thank …

Member Avatar for jooa
0
4K
Member Avatar for aveek

im trying to draw a curved line using mouse. there are three points on a straight line. a starting point, an ending point and a point in between. i want to draw a curved line by dragging the middle point in any direction. the other two points remain constant.

Member Avatar for VernonDozier
0
95
Member Avatar for VBNick

Hello~! ...again.. I got some help from you guys a while ago with this same app because it wouldn't run on winxp. It runs fine now, but my brother is still telling me he cant get it to work right...so rather than go through all the trouble of trouble shooting(he …

Member Avatar for Salem
0
258
Member Avatar for llemes4011

Hi. In my attempts to create an email client, netbean's GUI builder has made me very unhappy... so, I decided I'd rather code it by hand... not my best idea, but whatever. Now, I'm trying to nest a Vertical JSplitPane in a Horizontal JSplitPane, and I can't see the left …

Member Avatar for llemes4011
0
94
Member Avatar for get2tk

PLEASE HOW DO I START USING JSP TO BUILD WEB PAGES ON NETBEANS FROM SCRATCH.I HAVE LOOKED UP ALMOST EVERYWHERE AND IT KEEP CONFUSING ME.(I HAVE netbeans ide 6.1 VERSION). ALL MY CODES HAVE BEEN WRITTEN IN JAVA AND I NEED TO UPLOAD THEM USING WEB PAGES AND NOT JUST …

Member Avatar for memegha123
0
156
Member Avatar for rizillion

i need to how to give codings to buttons that are present in confirm dialog box. For Example if there are two buttons as "YES" and "NO" and if i click "YES" then the program should close. If i click no then th dialog box should return to the program. …

Member Avatar for peter_budo
0
164
Member Avatar for gshockneo

hi I have a simple log in form. I want that after user logs in , he should not be able to goto login page again using back button of browser. Does page reloads fresh when back button is clicked or it simply displays what was earlier. login.jsp [code] <% …

Member Avatar for peter_budo
0
109
Member Avatar for Web_Sailor

Hi, I am trying to create a HTTP file upload setup for a java application. So I have got a File Upload server which is working and a Client (I am not sure what changes I should do to make my Client code work with the server code) NEED HELP …

0
68
Member Avatar for mimsc

Hey Fellas...Im getting this error on a "select box"...im trying to parse some info: PWC6197: An error occurred at line: 88 in the jsp file: /jsp/cpanel/HomeSellerList.jsp PWC6199: Generated servlet error: string:///HomeSellerList_jsp.java:147: cannot find symbol symbol : method indexOf(java.lang.String) location: class java.lang.Object PWC6197: An error occurred at line: 88 in the …

Member Avatar for sillyboy
0
846
Member Avatar for CTUBren

I'm sure this is going to be really easy to figure out and might even be something like trying to use correct grammar (this has happened to me a few times), but I've stared at this code for hours upon hours and don't know why NetBeans says it's wrong. There …

Member Avatar for PopeJareth
0
89
Member Avatar for the_prox

Hi there, I need to write a program that draws a clock face with a time that the user enters in two text fields (one for the hours, one for the minutes). As far as I can tell I have all the code written, it's now just a matter of …

Member Avatar for VernonDozier
1
176
Member Avatar for emint

hi, i got class A which class got some graphics to display. when i run the program in class A its fine, but i when run from class B it display like 40 sec delay. any one who can help me? really need help!

Member Avatar for emint
0
107
Member Avatar for Talguy

I am trying to make a java sever code communicate with and iphone hello world app. When I run the iphone app it sends the length of the string first then sends the string. the Length of the string should be 2 but my server code prints out 33554432. Also …

Member Avatar for Talguy
0
175
Member Avatar for ragnarok511

I am having trouble with a project that is used to create a simple library database. The code does compile but during runtime, it throws a nullPointerException. It points to addBook in my main method. Here is my code: [code]public class Library { Book[] books; int numBooks; String address; static …

Member Avatar for ragnarok511
0
365
Member Avatar for VernonDozier

OK, I haven't done much with Serialization. I have a simple program that creates four JPanels with different background colors and adds them to a larger JPanel using a 2 x 2 GridLayout. That larger JPanel is added to a JFrame. I've written my own serialization code to override the …

Member Avatar for VernonDozier
0
1K
Member Avatar for iamwa

i am an IT STUDENT MY INSTRUCTUR HAS GIVEN ME ATASK TO BUILD WEB BROWSER IN JAVA AFTER GUI WHAT I HAD TO DO PLEASE HELP ME!!! NOT GIVE ME THE CODE JUST TELL ME EASY STEPS COMPLETE IT THANKS!!!

Member Avatar for saggy4
0
112
Member Avatar for ronpaul53

I can quite honestly say I am lost, having learnt HTML during the past 2 years and trying to understand a bit about java, but find myself very confused. Yes could look in books but find them equally confusing the same as when learning HTML and preferred to do more …

Member Avatar for ronpaul53
0
176
Member Avatar for baftjar

Task: Given input file A, translate the content to produce output file B Hi there, I need help in solving this domain problem. Any help will be appreciated. ====Scenario========== File A: Consists of multiple lines of data whereby each line is of form X;1.9,2;3,4.3; 5,6 Output file B, should consists …

Member Avatar for masijade
0
85
Member Avatar for multicoder

Hi, I have a strange situation to tackle.I have a paging for the website I am developing. there are few records in the table which i want to skip from to display in my list in the web page. But paging works on the total num rows as using mysql_num_rows(resultset)

Member Avatar for multicoder
0
107
Member Avatar for joshmo

I would like to know how one can make an installer, which I believe is supposed to copy needed files for an apllication to run to somewhere on the PC. I have read about how to make .jar files, and evaluted some softwares that can make installers. However, I have …

Member Avatar for peter_budo
0
105
Member Avatar for sotvisal

import javax.swing.*; class Customer { int id,rate,pre,cur; String name,sex; String read(String n) { return JOptionPane.showInputDialog(n); } int readInt(String n) { return Integer.parseInt(read(n)); } void out(String n) { JOptionPane.showMessageDialog(null,n); } public Customer() { id=1; name="Visal"; sex="Male"; pre=13214; cur=13362; rate=720; } int consumption(int pre,int cur) { return(cur-pre); } int payment(int rate) { …

0
67
Member Avatar for mahdi68
Member Avatar for jpd85

need help with outputting an array of objects to a text file. new to java so any help would be much appreciated thanks johnny

Member Avatar for kvprajapati
1
114
Member Avatar for davidnorth

Hello, I have a problem with my code and can't see what the difference can be. I am trying to change my JLabel text via a timer using .setText I have 2 small apps to demonstrate my problem. 1 - I have a JLabel within a JPanel within a JFrame, …

Member Avatar for davidnorth
0
566
Member Avatar for mr_andika
Member Avatar for peter_budo
-1
100
Member Avatar for anusha88

hi,i have a unique problem.actually i wish to put a polarchart developed using JFreechart on the frame that already has components placed on it.What i want to do is to make the particular component overlap the polarchart. How can i do so? i thought of creating the polar chart using …

Member Avatar for kvprajapati
0
318
Member Avatar for peter_budo

Currently I'm creating application to work with PDF documents, just for challenge. I want to know if there is better solution to my idea of possible approach. I broke down application GUI to four main components toolbar with image icons, jpanel for thumbnail preview, jpanel for single page view and …

Member Avatar for masijade
0
98
Member Avatar for sgsawant

[COLOR="Red"]The program is given at the bottom[/COLOR] To compile java programs in the command prompt I use the following command: C:\jtemp\MyPack>javac AccountBalance.java -d . Only then are the classes compiled and I am able to run the main() function. When I execute the above command a folder "MyPack" is created …

Member Avatar for sgsawant
0
416
Member Avatar for NewToThis

I have been trying to build a Java program to prompt the user to enter the radius of a circle and the diameter, circumference, and area will be output through a "System.out.printf" statement. I can get the program to prompt for the radius and it will display the diameter, but …

Member Avatar for NewToThis
0
102
Member Avatar for JChakra

Dear mates, I am am frustrated and bored to learn how to get or calculate coordinates data for Java Graphic API. for ex the GeneralPath 's function curveTo() takes 6 parameters namely x1,y2,x2,y2,x3,y3.I put some random coordinates data into these function and got a crap drawing. :( I want to …

Member Avatar for JChakra
0
201
Member Avatar for anshusharma

hello, i am new to web services.I may be asking this question wrongly.so forgive me. In my project i have to consume a webservice using java.Could u plz say me how to Create a client api in axis2 in java to consume the webservice that has been created in vb.net. …

Member Avatar for peter_budo
0
99
Member Avatar for vamsi.ac

Hi all i am new to this foru n this is my first topic, we use erp tool kits to design portals for colleges and schools. this erp toolkit generates the java code in making this portal. so we dont have to do anything with java. But i would like …

Member Avatar for JamesCherrill
0
89
Member Avatar for PatrixCR

Hi. I'm new to java programming. I have some questions: 1) Does every java source code's [B]class name[/B] (the name after the [I]class[/I] keyword, e.g. [I]class[/I] [B][I]Hello[/I][/B]) has to be started with an uppercase character? 2) Does the java source code's [B]file name[/B] (e.g. [I][B]Hello[/B][/I].java) has to be [U]exactly[/U] the …

Member Avatar for sincerelibran
0
320

The End.