ClearMessage method

This method clears the data buffer portion of the MQMessage object. Any Message Data in the data buffer is lost, because MessageLength, DataLength, and DataOffset are all set to zero.

The Message Descriptor (MQMD) portion is unaffected; an application may need to modify some of the MQMD fields before reusing the MQMessage object. If you wish to set the MQMD fields back to initial values you should use New to replace the object with a new instance.

Defined in: MQMessage class

Syntax:
Call MQMessage.ClearMessage()