GUI issues

Hello, I am kind of new to this programming deal with the emphasis on GUIs. What I need to do is to get the following program turned into a GUI using Jbuttons, text fields and so on. Any help would be appreciated.

import java.util.*;

class Practice{

public static void main(String[]args){

double L, Sy, Sh;

double p1, p2, p3, p4;

int V, I, R;

Scanner stump=new Scanner(System.in);

System.out.println(" Enter a double ");

L = stump.nextDouble();

System.out.println(" Enter an Integer ");

V = stump.nextInt();

System.out.println(" Enter a double ");

Sy = stump.nextDouble();

System.out.println(" Enter a double ");

Sh = stump.nextDouble();

System.out.println(" Enter an Integer ");

I = stump.nextInt();

System.out.println(" Enter an Integer ");

R = stump.nextInt();

p1 = 3*(L+1)/V*(Sh+2/Sy+2);

p2 = (R*R)-5*R+1/Math.abs(11-I);

p3 = Math.sqrt(p1 + p2);

p4 = Math.round (p3);

System.out.println("You can spend " +p4+ " hours doing nothing.");

}

}

[1127 byte] By [BugsyTalls03a] at [2007-11-27 2:31:19]
# 1

Did that mean that you want somebody to write a GUI equivalent on your behalf? Or did it mean that you want to acquire the knowledge to be able to do it yourself?

If the former, go and hire somebody. People don't like being asked to do other people's work for free here. If the latter, here's a link to a tutorial:

http://java.sun.com/docs/books/tutorial/uiswing/

DrClapa at 2007-7-12 2:46:00 > top of Java-index,Core,Core APIs...
# 2

no, absolutly not. I am just stuck more on the issue of getting the mathematical formula attached to a button, so when clicked the formula would be executed. I cannot seem to get the user entered numbers to be interpreted into the formula for execution.

I apologize for the misinterpretation and appreciate the URL.

Thanx

BugsyTalls03a at 2007-7-12 2:46:00 > top of Java-index,Core,Core APIs...
# 3
Sure, you're welcome. To get started, just try to get something simple working, not necessarily related to your exact problem. Then think of what your screen should look like to accept those numbers from the user.
DrClapa at 2007-7-12 2:46:00 > top of Java-index,Core,Core APIs...