MulticastAddress Property

MessageQueue.MulticastAddress Property


Introduced in MSMQ 3.0. Gets or sets the multicast address associated with the queue.

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

public string MulticastAddress { get; set; }

Property Value

Type: System.String

A String that contains a valid multicast address (in the form shown below) or null, which indicates that the queue is not associated with a multicast address.


Exception Condition

MSMQ 3.0 is not installed.

The MulticastAddress property is used to associate a non-transactional queue with a multicast address that can be used when sending messages. You cannot associate a transactional queue with a multicast address. When the sending application sends messages to a multicast address, Message Queuing sends a copy of the message to every queue associated with that address.

IP multicast addresses must be in the class D range from to, which corresponds to setting the first four high-order bits equal to 1110. However, only certain ranges of addresses in this range are unreserved and available for sending multicast messages. For the latest list of reserved multicast addresses, see the Internet Assigned Number Authority (IANA) Internet Multicast Addresses Web page. There are no restrictions on the port number.

If several source computers are sending multicast messages and you want a specific queue to receive messages from only one source computer, each source computer must send messages to a different combination of IP address and port number.

To dissociate a queue from a multicast address, set the MulticastAddress property to a zero-length string. Do not set it to null, as this will result in a ArgumentNullException.

The following table shows whether this property is available in various Workgroup modes.

Workgroup mode


Local computer


Local computer and direct format name


Remote computer


Remote computer and direct format name


.NET Framework
Available since 2.0
Return to top
© 2016 Microsoft