This documentation is archived and is not being maintained.

MessageQueue.Refresh Method

Refreshes the properties presented by the MessageQueue to reflect the current state of the resource.

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

public void Refresh ()
public void Refresh ()
public function Refresh ()

Refresh synchronizes the properties of a MessageQueue with its associated Message Queuing server resource. If any property, such as Label or Category, has changed on the server since the time the MessageQueue was created, Refresh updates the MessageQueue with the new information.

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

Workgroup mode

Available

Local computer

Yes

Local computer and direct format name

Yes

Remote computer

No

Remote computer and direct format name

Yes

The following code example demonstrates the use of Refresh.


// Connect to a queue on the local computer.
MessageQueue queue = new MessageQueue(".\\exampleQueue");

// Refresh the queue's property values to obtain its current state.
queue.Refresh();


// Connect to a queue on the local computer.
MessageQueue queue = new MessageQueue(".\\exampleQueue");
// Refresh the queue's property values to obtain its current state.
queue.Refresh();

  • 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
Show: