Adds or sets a double variable with a given name and value. If a variable with the same name already exists, the value of that variable is updated.

Namespace:  SingularSys.Jep
Assembly:  Jep (in Jep.dll) Version: 1.1.0.0 (1.0.0)

Syntax

C#
public Variable AddVariable(
	string name,
	double value
)
Visual Basic (Declaration)
Public Function AddVariable ( _
	name As String, _
	value As Double _
) As Variable
Visual C++
public:
Variable^ AddVariable(
	String^ name, 
	double value
)

Parameters

name
Type: System..::.String
the name of the variable to be added
value
Type: System..::.Double
the value of the variable to be added

Return Value

the Variable instance

Exceptions

ExceptionCondition
SingularSys.Jep..::.JepExceptionif an attempt is made to set the value of a constant variable

See Also