Share this page

# jms_set_general_property

Sets a general property in the user context.

Web Services Functions (SOAP, WEB_SERVICE, Silverlight)

    int jms_set_general_property( const char * StepName, const char * Name, const char * Value );

This function returns LR_PASS (0) on success or LR_FAIL (1) on failure. Note that LR_PASS and LR_FAIL generally indicate whether the function call completed without an exception, and not that the test step succeeded.

All input string arguments (char type) except the step name can be parameterized using standard parameterization.

StepName | The name of the step, as it appears in the test tree. Any text can be used.
Name | The name of the property. The only supported property is "JMS_MESSAGE_TYPE"
Value | The value of the property, one of: TextMessage. Send with the TextMessage format. BytesMessage. Send with the BytesMessage format. Default Send with the default format.

The jms_set_general_property sets a general property in the user context.

JMS can be sent with several message body formats. The most common are TextMessage and BytesMessage. By default, the test run infrastructure tries to resolve the desired format based on the message content type. If the content type is Text/* then it is sent using TextMessage. Otherwise, it is sent using BytesMessage.

To override this default behavior, set the message format with jms_set_general_property API function before sending the message.

If no JMS_MESSAGE_TYPE is specified, the default is used.

## Example

This example shows the use of jms_set_general_property to set the message format to BytesMessage.

    jms_set_general_property("step1", "JMS_MESSAGE_TYPE", "BytesMessage");

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