32,204 Topics

Member Avatar for
Member Avatar for tankeetanx

[CODE]import java.io.*; public class Calculator{ public static void main(String[] args){ BufferedReader dataIn=new BufferedReader(new InputStreamReader(System.in)); int x=1, y=1; String Str_1,Str_2; System.out.println("Enter an Equation: "); try { Str_1=dataIn.readLine(); System.out.print("Enter another Equation: "); Str_2=dataIn.readLine(); x=Integer.parseInt(Str_1); y=Integer.parseInt(Str_2); x = x+y; x = x-y; x = x*y; x = x/y; } catch(ArithmeticException e) { System.out.println("Divide …

Member Avatar for VernonDozier
0
176
Member Avatar for sotvisal

import java.util.*; class Matrice { private int[][] a; private int row; private int col; public static Scanner in() { return new Scanner(System.in); } public static void out(String m) { System.out.print(m); } public static int readInt(String m) { out(m); return in().nextInt(); } public Matrice() { row=2; col=2; a=new int[row][col]; } public …

Member Avatar for JamesCherrill
0
162
Member Avatar for digitalbeat

I'm working on a program that first launches a frame with various text fields. After they are filled in, the information is submitted by simply clicking the submit button. I have the frame down, the text fields and the buttons, and I have the class where all my data and …

Member Avatar for TheWhite
0
151
Member Avatar for bervin

Okay. I'm in need of desperate help and really hope someone can help me type out the entire code for a simple basic java project. 1)adherence to java naming conventions 2)At least one static method other than main 3)providing int, double and string inputs 4)proper selection construct (switch-case or if-else) …

Member Avatar for TheWhite
0
163
Member Avatar for jadeite100

Hi All: I am using windows 2000 server with Eclipse. In the dost prompt, I ran the file run_sqlldrTest2.cmd and it loaded record into the Oracle database. I tried to do the same thing in java calling the run_sqlldrTest2.cmd. In java it states the "The command line job - -executed …

Member Avatar for dixitworld
0
952
Member Avatar for ChangBroot

Hi, I want to create a typewrite/typing java app. I want to change the color of a text to be different, whenever the user types the wrong character in a JTextArea. For example, if the user was supposed to type "My Book" and s/he types "My Bok", I want the …

Member Avatar for ChangBroot
0
370
Member Avatar for emint

hi all how can i draw rectangle for each graphic. on the picture, each rectangle is create as graphic. pls help.

Member Avatar for wildgoose
0
94
Member Avatar for damn

I have to create a GUI like Netica that can create decision networks (influence diagrams) I want to click on a rectangle icon and be able to drop it on the editor and make the rectangle bigger. How do I do that? I know it is drag and drop but …

0
30
Member Avatar for gotm

So I have a JComboBox, which contains recipe names. I want, when the recipe name is changed, for the label that is an icon of the rating (1 to 5) stars, based on my recipe object, to change as well. My code seems like it should work perfect but it …

Member Avatar for llemes4011
0
1K
Member Avatar for jakx12

Ok so im basically new to computer vision, but i would love to expand my knowledge in java and do some computer vision stuff. So what would be the best library to use with lots of documentation and support? Essentially id like to do object tracking and see if there …

0
63
Member Avatar for TheWhite

Well, I'm doing pretty good with my WebChat application, but I was thinking to add some smileys! At first, I would like the app to auto detect the smileys in standard form from a given string and place the image in its place, but I came across the problem: how …

Member Avatar for TheWhite
0
494
Member Avatar for smoore

Okay I would like to set a Mnemonic for a JButton so that if I press the right arrow key the button will be activated. However I can not find what the command for that would be. Right now I have it so that you can hold down alt+Right to …

Member Avatar for TheWhite
0
107
Member Avatar for ashish2234

i AM really new at java and i have just created a very simple diesign of something that is static but should play mp3 files, loaded the required jmf as well ...I want when i click on the jtable and then play song starts playing ..its is not happening here's …

Member Avatar for ashish2234
0
102
Member Avatar for jakx12

Ok so basically I just wanted to see if anyone had any ideas for me. Basically I want to do a project in java because i havnt done one for ages. Im fluent in java so that means i can do relatively complicated things. Id prefer for some software ideas …

Member Avatar for jakx12
0
113
Member Avatar for violet_blossom

Hi, I'm really, really new to Java, but I've created a game, and in a separate file the GUI, but I don't know how to attach the functions of the program to the GUI. This is my program: [code] import java .util.*; class bust { public static void main (String …

Member Avatar for TheWhite
0
95
Member Avatar for alrevolver

Hi, We have a java web application where users will be submitting videos. I'm trying to write a java program that is able to convert any movie file into compressed SWF video and FLV streaming video formats. The code should convert almost all popular file extensions such as AVI, MPEG, …

Member Avatar for test
0
157
Member Avatar for beshoyatef

Here i try to draw line by mouse pn panel but it is not appear here is my code: [ICODE] import java.awt.BorderLayout; import java.awt.Color; import java.awt.Dimension; import java.awt.Graphics; import java.awt.GridLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.MouseAdapter; import java.awt.event.MouseEvent; import javax.swing.ImageIcon; import javax.swing.JButton; import javax.swing.JComponent; import javax.swing.JFrame; import javax.swing.JPanel; public class …

Member Avatar for JamesCherrill
0
117
Member Avatar for jonny_java

Hi All, I hope someone can offer some help / advice. I need to plot a fairly simple line chart/graph, using some data generated previously from another Java program (run from the console) that is output to a text file. I'm really struggling trying to produce a viewable line chart/graph …

Member Avatar for jonny_java
0
251
Member Avatar for Nathan Campos

Hello, I'm learning Java ME and i was building an application that is a simple contact book, but in the main form it only have menus, because i don't know how i can list the registry's on it, remember that i want to list only the names in the list …

Member Avatar for peter_budo
0
168
Member Avatar for Nathan Campos

Hello, I'm learning Java ME and when i complete the development of an application that uses RecordStore, it's simple a contact book, but when i completed the code i see that my program have an error and i use Eclipse, then it marks wrong codes in the left of the …

Member Avatar for Nathan Campos
0
104
Member Avatar for jakx12

The title says it all. Is it possible if so how would you code the kernel etc. Also is there an open-source project or something with the kernel etc already written? Again many thanks, jakx12.

Member Avatar for jakx12
0
83
Member Avatar for bervin

If choice is [COLOR="Red"]1[/COLOR], user will be prompted to enter the month and then the person and salary earned. Total number of person entered should not exceed 8. An empty entry on the "Enter person" prompt should allow user to break out of the loop. //i have been stuck on …

Member Avatar for TheWhite
0
92
Member Avatar for anglok

Hello, Is there a way to center or offset a canvas component inside of a Java Frame (AWT)? I've tried a number of strategies based around frame.add(canvas), and whether I'm using a full screen frame of not, it's always aligning at the top left of the frame. Thanks for any …

0
53
Member Avatar for TheWhite

I'm writing a WebChat application using the socket functions in java. I'm able to listen for incoming sockets on the server side and connect from the client side just fine, but I'm having a problem communicating from the client to the server to ALL the clients. Right now, I have …

Member Avatar for TheWhite
0
194
Member Avatar for malikfirose

i am a Bsc software engineering undergraduate , can any one tell me a project which is related to java service oriented architecture ? ,i am searching for a final year project. and i thought of doing it on java SOA if any one can suggest me a project topic …

0
61
Member Avatar for llemes4011

Hello. I have an undecorated JFrame (Which is rather boring by itself), and I would like to know how to get a drop shadow effect for it. I have researched it, but I haven't found anything, anyone have any ideas? Thanks in advance!!!

Member Avatar for JamesCherrill
0
264
Member Avatar for titosd

Hello, I have a question, in my program I want to read a text field then to convert it to Color, How Can I do this ? I try this, but I didn't know if this is right : [code]String colorString = getCarTextButtons()[3].getText(); Color color = Color.getColor(colorString);[/code]

Member Avatar for JamesCherrill
0
3K
Member Avatar for Maymoon

hi everybody, I'm having a problem on what to do next in my project. below is what i need to do. if any body let me know if i'm doing it right and if i need more classes. help on boolean, clone and finalize method. Thank you... A library needs …

Member Avatar for sneaker
0
242
Member Avatar for kvass

Hi everyone! This code runs without throwing exceptions and stuff, but it doesn't exactly run when I click the "Submit" button -- what is supposed to happen is that I click it and it generates a random number. What happens is either nothing or if I get lucky and click …

Member Avatar for kvass
1
134
Member Avatar for Nathan Campos

Hello, I'm learning Servlets technology, but i'm already a Java developer and i want to know how i can develop a servlet that have two pages, the first is a page that have a button and two text fields, one field of title and the other a memo field, but …

Member Avatar for kvprajapati
0
73

The End.