Partager via


PROPID_Q_PRIV_LEVEL (Windows Embedded CE 6.0)

1/6/2010

Optional. This property specifies the privacy level required by the queue.

The privacy level determines how the queue handles encrypted messages.

  • Type Indicator
    VT_UI4
  • PROPVARIANT Field
    ulVal
  • Property Values
    This property can only be set to the following value.

    Value Description

    MQ_PRIV_LEVEL_NONE

    The queue accepts only nonprivate (clear) messages.

Remarks

The embedded implementation of MSMQ does not support privacy levels.

To set the privacy level when creating the queue, specify PROPID_Q_PRIV_LEVEL in the MQQUEUEPROPS structure and call MQCreateQueue.

To retrieve the privacy level of a queue, specify PROPID_Q_PRIV_LEVEL in the MQQUEUEPROPS structure and call MQGetQueueProperties and examine its returned value.

Examples

The following examples show how PROPID_Q_PRIV_LEVELis specified in the MQQUEUEPROPS structure for setting and retrieving the privacy level of the queue.

To set the privacy level

DWORD dwPrivacyLevel = MQ_PRIV_LEVEL_NONE;
aPropID[i] = PROPID_Q_PRIV_LEVEL;        // Property identifier
aVariant[i].vt = VT_UI4;                 // Type indicator
aVariant[i].ulVal = dwPrivacyLevel;      // Privacy level of queue
i++;

To retrieve the privacy level

aPropID[i] = PROPID_Q_PRIV_LEVEL;       // Property identifier
aVariant[i].vt = VT_UI4;                // 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
MQCreateQueue
MQGetQueueProperties
MQQUEUEPROPS