lr.save_int

Saves an integer to a parameter

int lr.save_int ( int value, String param_name);
String and Parameter FunctionsJava Syntax

Arguments

NameComments
valueThe integer value to assign to the parameter.
param_nameThe name of the parameter.

The lr.save_int function assigns an integer to a parameter. This function is useful in correlating queries. To determine the value of the parameter, use the lr.eval_int function.

Return Values

This function returns LR_PASS (0) on success, and LR_FAIL (1) on failure. Note that in many cases, this return value indicates the technical success of the function, and not the result. For example, a function that registers a string to be found in a subsequent step returns LR_PASS to indicate that the registration was successful. This does not indicate that the string was found in the server response.

Parameterization

You cannot use standard parameterization for any arguments in this function.

Example

In the following example, lr.save_int assigns the integer 5433 to the parameter ID. This parameter is then used in an output message.

lr.save_int( 5433, "ID" );
    // ...
lr.output_message("Get identification number: " + lr.eval_int("<ID>") );