Share this page

# web_service_set_option

Web Services Functions (SOAP, WEB_SERVICE, Silverlight)

Sets an option before a call to a web service.

    int web_service_set_option( const char *OptionName, const char *OptionValue );

OptionName | The name of the web service option. Case sensitive.
OptionValue | The value of the option. Not case sensitive.

The web_service_set_option function changes the settings for all following calls to a web service.

This function is not recorded. Add it manually to the script before a web_service_call if you need one of these options:

Option Name | Usage
--- | ---
DoNotValidateSecurity | If server response includes a security token, the response may not match the ExpectedResponse argument to web_service_call. Set to true to ignore the security token.
ExcludeWseHeaders | Set to true to disable sending WS-Addressing in a web_service_call.
HandleMIMEResponse | Set to true if the SOAP response body is in MIME format.

## Return Values

This function returns LR_PASS (0) on success, and LR_FAIL (1) on failure.

## Parmaterization

Standard parameterization is not available for this function.

## Example

    web_service_set_option("DoNotValidateSecurity", "true");

    web_service_call( "StepName=EchoBoolean_101",
    	"SOAPMethod=EchoService|EchoServicePort|EchoBoolean",
    	"ResponseParam=response",
    	"Service=EchoService",
    	"ExpectedResponse=SoapResult",
    	"Snapshot=t1444878757.inf",
    	BEGIN_ARGUMENTS,
    	"Input=false",
    	END_ARGUMENTS,
    	BEGIN_RESULT,
    	END_RESULT,
    	LAST);

Tips to improve your search results... VuGen Function Reference Version 26.1 Function Reference 26.1 All View Local Help Center View Online Help Center Version: