The MQSetMessageReplyTo function specifies the destination where replies to this message should be sent.
MQSetMessageReplyTo (const MQMessageHandle messageHandle, const MQDestinationHandle destinationHandle);
MQStatus. See the MQStatusIsError() function for more information.
A handle to a message expecting a reply.
The destination to which the reply is sent. Usually this is a handle to a destination that you created using the MQCreateDestination() function or the function MQCreateTemporaryDestination(). The handle is still valid when this function returns.
The sender uses the MQSetMessageReply function to specify a destination where replies to the message can be sent. This can be a normal destination or a temporary destination. The receiver of a message can use the MQGetMessageReplyTo() function to determine whether a sender has set up a destination where replies are to be sent. The advantage of setting up a temporary destination for replies is that Message Queue automatically creates a physical destination for you, rather than your having to have the administrator create one if the broker’s auto_create_destination property is turned off.