WriteNullTerminatedString method

This method performs a normal WriteString and pads any remaining bytes up to the specified length with null. If the number of bytes written by the initial write string is equal to the specified length then no nulls are written. If the number of bytes exceeds the specified length then an error (reason code MQRC_WRITE_VALUE_ERROR) is set.

DataOffset is incremented by the specified length if the method succeeds.

Defined in: MQMessage class

Syntax:
Call MQMessage.WriteNullTerminatedString(value$, length&)

Parameters:

value$ String. Value to be written.

length& Long. Length of string field in bytes.