Example: lr.error_message

In the following example, lr_error_message sends a message to the output window or log file if login fails. "Iteration" "username" and "ssid" are parameters defined with the VuGen UI.

status = web.url( "www.abc.com", _
	"URL=https://secure.computing.com//login.asp?user=<username>&session=<ssid>", _
	    "RecContentType=text/html")

if (status = lr.FAIL) then
    lr.error_message   _
         lr.eval_string ( "Error at iteration <Iteration>, status = " ) _
         + Cstr(status)
Example: Output:
Notify: Parameter Substitution: parameter "username" = "Elinor"
Notify: Parameter Substitution: parameter "ssid" = "1122"
Continuing after Error -27798: Could not resolve address of host secure.computing.com     [MsgId: MERR-27798]
web_url("www.abc.com") highest severity level was "continue on error", 0 body bytes, 0 header bytes     [MsgId: MMSG-26388]
Continuing after error in Vuser script.
Notify: Parameter Substitution: parameter "Iteration" = "1"
Error: Error at iteration 1, status = 1