Instruction to read values

Hi!How can I insert a value to a variable? I mean, a instruction that gives the posibility to the user to insert a value. Just like a read in Pascal.Best regards
[182 byte] By [karma1234a] at [2007-10-3 4:00:39]
# 1

> Hi!

> How can I insert a value to a variable? I mean, a

> instruction that gives the posibility to the user to

> insert a value. Just like a read in Pascal.

> Best regards

That question is just to vague. How do you want your user to insert the value?

From GUI, command prompt or File?

If you look at the API it has everything that you need to read from, according to your choice.

lupansanseia at 2007-7-14 21:59:43 > top of Java-index,Java Essentials,New To Java...
# 2
From command. Like a read in Pascal.For examplea = integer"Insert the value for the first number"read a;In this case, the program is asking the user for a number, and the instruction read allows the user to insert a value to the "a" variable.
karma1234a at 2007-7-14 21:59:43 > top of Java-index,Java Essentials,New To Java...
# 3

> From command. Like a read in Pascal.

> For example

> a = integer

> "Insert the value for the first number"

> read a;

>

> In this case, the program is asking the user for a

> number, and the instruction read allows the user to

> insert a value to the "a" variable.

Dont know how pascal works. Never done programming in it.

But read the following article, it has the thing you wnat to to(at least i

think thats what you want to do)

http://www.devdaily.com/java/edu/pj/pj010005/index.shtml

BTW: learn to use google. It will give you answers right away.

lupansanseia at 2007-7-14 21:59:43 > top of Java-index,Java Essentials,New To Java...
# 4
Thnx.It works. I will use google more often :-)
karma1234a at 2007-7-14 21:59:43 > top of Java-index,Java Essentials,New To Java...