Reading Messages from a Dead-Letter Queue (COM) (Windows CE 5.0)
To read non-transactional messages from a dead-letter queue you must first obtain the machine identifier (GUID) of the computer associated with the DEADLETTER.
The machine identifier is combined with the "Machine" and "DEADLETTER" keywords to create the format name of the queue. Here is the syntax of format name for the dead-letter queue.
Machine=MachineGUID;DEADLETTER
To retrieve a message from a dead-letter queue
- Declare the variables needed to retrieve the message.
- Call MSMQApplication.MachineIdOfMachineName to obtain the machine identifier.
- Construct the format name of the dead-letter queue.
- Declare the variables needed to retrieve the message.
- Call MSMQQueueInfo.Open to open the queue with receive access.
- Call MSMQQueue.Receive to retrieve the first message in the queue.
- Call MSMQQueue.Close to close the dead-letter queue.
See Also
MSMQ Application Development | MSMQ COM Support | Using the COM Components | MSMQ Security
Send Feedback on this topic to the authors