PROPID_M_EXTENSION_LEN

This property specifies the length of the information in the PROPID_M_EXTENSION property.

  • Type Indicator
    VT_UI4 (or VT_NULL)
  • PROPVARIANT Field
    ulVal
  • Property Values
    The size (in bytes) of the extension information specified by PROPID_M_EXTENSION.

Remarks

PROPID_M_EXTENSION_LEN is used only by the receiving application. It is used whenever the receiving application specifies PROPID_M_EXTENSION in the MQMSGPROPS structure.

To retrieve extension information, set PROPID_M_EXTENSION and PROPID_M_EXTENSION_LEN in the MQMSGPROPS structure. Then call MQReceiveMessage and examine the returned values. When specifying PROPID_M_EXTENSION_LEN, you can set its Type Indicator to VT_NULL. When the Type Indicator is set to VT_NULL, MSMQ sets the VT field to the appropriate type indicator.

When MQReceiveMessage succeeds, first test the returned value of PROPID_M_EXTENSION_LEN to see if any extension information exists. A returned value of 0 indicates that no information was sent by the sending application. A nonzero returned value indicates the extension information was returned by PROPID_M_EXTENSION.

If MQReceiveMessage fails, returning an MQ_ERROR_BUFFER_OVERFLOW error, use the returned value of PROPID_M_EXTENSION_LEN to reallocate the extension information buffer and call MQReceiveMessage again.

This property is not needed when you are using COM components.

Example

This example shows how PROPID_M_EXTENSION_LEN and PROPID_M_EXTENSION are specified in the MQMSGPROPS structure.

aMsgPropId[i] = PROPID_M_EXTENSION_LEN;     // Property ID
aMsgPropVar[i].vt = VT_UI4;                 // Type indicator
i++;

aMsgPropId[i] = PROPID_M_EXTENSION;         // Property ID
aMsgPropVar[i].vt = VT_UI1 | VT_VECTOR;     // Type indicator
i++;

Requirements

Runs on Versions Defined in Include Link to
Windows CE OS 2.0 and later. Versions prior to 2.12 require the MSMQ add-on pack. Mq.h    

Note   This API is part of the complete Windows CE OS package as provided by Microsoft. The functionality of a particular platform is determined by the original equipment manufacturer (OEM) and some devices may not support this API.

See Also

MQReceiveMessage, PROPID_M_EXTENSION, MQMSGPROPS

 Last updated on Tuesday, July 13, 2004

© 1992-2000 Microsoft Corporation. All rights reserved.