equivalent val funtion in visual basic

Hi, i have an assignment to convert a program from VB to Java. Does anyone know what function in java that has the same utility?

This is the desciption of val function:

http://msdn2.microsoft.com/en-us/library/k7beh1x9(VS.71).aspx

[249 byte] By [firstalliancea] at [2007-11-27 10:23:42]
# 1

Java uses Classes with Methods. I would search the API for some guidance

http://java.sun.com/javase/6/docs/api/

Brightness86a at 2007-7-28 17:23:26 > top of Java-index,Java Essentials,New To Java...
# 2

val() function in VB returns the value of a string in java you need to parse the string.

Integer.parseInt(String) returns int

Float.parseFloat(String) returns float

Yannixa at 2007-7-28 17:23:26 > top of Java-index,Java Essentials,New To Java...