Export (0) Print
Expand All

Message.Acknowledgment Property

Gets the classification of acknowledgment that this message represents.

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

[MessagingDescriptionAttribute("MsgAcknowledgement")]
public Acknowledgment Acknowledgment { get; }

Property Value

Type: System.Messaging.Acknowledgment
One of the Acknowledgment enumeration values.

ExceptionCondition
InvalidOperationException

The message has not been sent. This property can only be read on messages retrieved from a queue.

-or-

The message queue is filtered to ignore the Acknowledgment property.

When you receive a message from an administration queue, read the Acknowledgment property to verify the status of the original message.

When a message is sent to its destination queue, Message Queuing can be requested to post an acknowledgment message. Such a message can indicate, for example, whether the message arrived and was retrieved within specified time-outs, or it can indicate what went wrong in the case of delivery failure. The destination queue returns acknowledgment messages and posts them to the administration queue specified in the original message's AdministrationQueue property. The Id property of an acknowledgment message identifies the acknowledgment message, not the original message. You can find the identifier of the original message in the acknowledgment Message instance's CorrelationId property.

If this Message instance represents an acknowledgment message, the Acknowledgment property specifies the type of acknowledgment. Otherwise, the Acknowledgment property contains the value Normal.

Use the AcknowledgeType property of the original message to specify the circumstances under which acknowledgments will be returned.

.NET Framework

Supported in: 4.5.2, 4.5.1, 4.5, 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft