PROPID_M_EXTENSION_LEN (Windows Embedded CE 6.0)
1/6/2010
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 when the receiving application specifies PROPID_M_EXTENSIONin the MQMSGPROPS structure.
To retrieve extension information, set PROPID_M_EXTENSIONand PROPID_M_EXTENSION_LENin 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, test the returned value of PROPID_M_EXTENSION_LEN to see if 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 use COM components.
Examples
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++;
Note
OS versions prior to 2.12 require the MSMQ add-on pack.
Requirements
Header | mq.h |
Windows Embedded CE | Windows CE 2.0 and later |
See Also
Reference
MSMQ Properties
MQReceiveMessage
PROPID_M_EXTENSION
MQMSGPROPS