This topic has not yet been rated - Rate this topic

Message.Extension Property

Gets or sets additional, application-defined information associated with the message.

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

public byte[] Extension { get; set; }
/** @property */
public byte[] get_Extension ()

/** @property */
public void set_Extension (byte[] value)

public function get Extension () : byte[]

public function set Extension (value : byte[])

Property Value

An array of byte values that provides application-defined information associated with the message. The default is a zero-length array.
Exception typeCondition

InvalidOperationException

The message queue is filtered to ignore the Extension property.

ArgumentException

The Extension property is a null reference (Nothing in Visual Basic).

The Extension property provides for application-defined information, like a large binary object, that is associated with the message. It is the responsibility of the receiving application to interpret the contents of the Extension property.

Where possible, you should include message data in the Body property of the message rather than the Extension property.

When working with foreign queues, use the Extension property to specify message properties that do not exist in Message Queuing.

A foreign queue exists in a queuing system other than Microsoft Message Queuing. Message Queuing communicates with such queues through a connector application.

  • Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see .

Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

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

.NET Framework

Supported in: 2.0, 1.1, 1.0

.NET Compact Framework

Supported in: 2.0
Did you find this helpful?
(1500 characters remaining)

Community Additions

ADD
© 2013 Microsoft. All rights reserved.