The Access property of the MSMQQueue object provides the access mode in which the queue was opened.
Property Access As Long
A Long set to one of the following values:
Messages can only be sent to the queue.
Messages can only be looked at. They cannot be removed from the queue.
Messages can be retrieved (read and removed) from the queue, peeked at, or purged.
MQ_PEEK_ACCESS | MQ_ADMIN_ACCESS
Messages in the local outgoing queue can only be peeked at (read without being removed from the queue).
MQ_RECEIVE_ACCESS | MQ_ADMIN_ACCESS
Messages in the local outgoing queue can be retrieved (read and removed from the queue), peeked at (read without being removed from the queue), or purged (deleted).
The Access property returns the access mode specified when the queue was last opened, regardless of whether the queue is currently open or closed.
Windows NT/2000/XP: Included in Windows NT 4.0 SP3 and later.
Windows 95/98/Me: Included in Windows 95 and later.
Header: Declared in Mqoai.h.
Library: Use Mqoa.lib.