What's new

Java Jframe

  • Thread starter toa matoro
  • Start date
  • Views 311
toa matoro

toa matoro

Enthusiast
Messages
94
Reaction score
8
Points
55
Sin$
7
so i have to make a program thats ask for user input for integers. then they could add all the integer, sum odd, or sum even so basically what im asking is when i add a sum all button how do i make it appear in the text field

http://imgur.com/U4LXEOa
 
Im4eversmart

Im4eversmart

The hacks are real
Glitcher Modder Programmer
Messages
2,156
Reaction score
1,903
Points
455
Sin$
7
need to know how to program the sum all button so it shows the answer on the textfield on the bottom of the program
Assuming you have the answer:

Use a button listener.
Attach it to the sum all button.
In the listener method, call setText on the text field. You can use String.valueof(number) if it doesn't like the parameter.
 
Top Bottom
Login
Register