MessageQueuePermissionEntry Constructor (MessageQueuePermissionAccess, String)

 

Initializes a new instance of the MessageQueuePermissionEntry class with the specified permission access levels and the path of the queue.

Namespace:   System.Messaging
Assembly:  System.Messaging (in System.Messaging.dll)

public MessageQueuePermissionEntry(
	MessageQueuePermissionAccess permissionAccess,
	string path
)

Parameters

permissionAccess
Type: System.Messaging.MessageQueuePermissionAccess

A bitwise combination of the MessageQueuePermissionAccess values. The PermissionAccess property is set to this value.

path
Type: System.String

The path of the queue that is referenced by the MessageQueue object. The Path property is set to this value.

The following code example creates a new instance of MessageQueuePermissionEntry.

// Connect to a queue on the local computer.
MessageQueue queue = new MessageQueue(".\\exampleQueue");

// Create a new instance of MessageQueuePermissionEntry.
MessageQueuePermissionEntry entry = new MessageQueuePermissionEntry(
    MessageQueuePermissionAccess.Receive,
    queue.Path);

.NET Framework
Available since 1.1
Return to top
Show: