aspose file tools*
The moose likes Beginning Java and the fly likes Sample GUI program to add two numbers Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Sample GUI program to add two numbers" Watch "Sample GUI program to add two numbers" New topic
Author

Sample GUI program to add two numbers

Sunali Anu
Greenhorn

Joined: Jun 04, 2007
Posts: 14
Can some body give me a sample program to add two text fields which takes numbers as the input and give me output by adding the two numbers upon clicking a 'add' button.

Thanks much.
marc weber
Sheriff

Joined: Aug 31, 2004
Posts: 11343

That sounds like a great homework assignment. Do you have any code yet? What are your specific questions about this?


"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org
Sunali Anu
Greenhorn

Joined: Jun 04, 2007
Posts: 14
Nevermind... I figured it out.. I had questions about the ActionListeners needs to be implemented to do this... But i know what they are now... Thanks...
Amit Ghorpade
Bartender

Joined: Jun 06, 2007
Posts: 2716
    
    6

Hi,
But still if you want to give a try, I would recommend the use of an applet because it is pretty simple and easy to use than an application (just for learning purpose) because here you wont require any frame, container,nothing.So you dont wast time in getting other things done.



Hope this helps


SCJP, SCWCD.
|Asking Good Questions|
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Sample GUI program to add two numbers