NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Creating MessageQueue Components

For an overview of the issues of creating MessageQueue components, see MessageQueue Component Creation.

To create an instance of the MessageQueue component programmatically

  1. Create an instance of the MessageQueue class in code. You code might look like this:
    [Visual Basic]
    Dim myMQ as New System.Messaging.MessageQueue
    [C#]
    System.Messaging.MessageQueue myMQ =
       new System.Messaging.MessageQueue();
  2. Set the Path property to determine which existing queue you want your component to reference. Your code might look like this:
    [Visual Basic]
    myMQ.Path = ".\MyNewQueue"
    [C#]
    myMQ.Path = @".\MyNewQueue";
    Note   You can refer to the queue by the path to the queue, the queue's automatically generated format name, or by the non-unique descriptive label of the queue. Each of these ways of referencing a queue has its advantages and disadvantages. For details, see Queue Reference Recommendations.
  3. Configure any other necessary properties for your queue. For details, see Message Queue Configuration Properties .

See Also

MessageQueue Component Creation | Message Queue Configuration Properties  | Accessing Server Explorer