ReceiveCompletedEventArgs.Message Property


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Gets the message associated with the asynchronous receive operation.

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

public Message Message { get; }

Property Value

Type: System.Messaging.Message

A Message that represents the end result of the asynchronous receive operation.

Exception Condition

The Message could not be retrieved. The time-out on the asynchronous operation might have expired.

The Message property provides a means for retrieving the message that initiated the end of the asynchronous receive operation.

MessageQueue.EndReceive is called the first time the Message property is read, so it is not necessary to call EndReceive prior to getting the value of this property.

.NET Framework
Available since 1.1
Return to top