Sun Java System Message Queue 4.3 Developer's Guide for C Clients


The MQGetMessageProperties function passes back the user-defined properties for a message.

MQGetMessageProperties (const MQMessageHandle messageHandle,
                              MQPropertiesHandle * propsHandle);

Return Value

MQStatus. See the MQStatusIsError() function for more information.



A handle to a message whose properties you want to get.


Output parameter for the handle to the message properties.

The MQGetMessageProperties function allows you to get application-defined properties for a message. Properties allow an application, via message selectors, to select or filter messages on its behalf using application-specific criteria. Having obtained the handle, you can either use one of the MQGet...Property functions to get a value (if you know the key name) or you can iterate through the properties using the MQPropertiesKeyIterationStart() function.

You will need to call the function MQFreeProperties() to free the resources associated with this handle after you are done using it.

Common Errors