Name

ValueOf — Evaluates a single line of code

Synopsis

obj ValueOf(line);
string line;

Description

This method evaluates a line of code. It can be, for example, a simple name of a variable or a more complex line

Parameters

line

the line to evaluate

Returns

the object resulting from the evaluation or an empty string if the evaluation caused the error Err_UndefinedIdentifier.

See Also

Eval

Note

Examples:

// prints value of aname or empty string
// if aname doesn't exist
$curScript.ValueOf("aname")
// prints value of myString.length
$curScript.ValueOf("myString.length")

Use Eval to evaluates real blocks of code