Imports System
Imports System.Messaging
Public Class MyNewQueue
Public Shared Sub Main()
Dim numberQueues As Int32 = 0
Dim myQueueEnumerator As MessageQueueEnumerator = MessageQueue.GetMessageQueueEnumerator()
While myQueueEnumerator.MoveNext()
Console.WriteLine(myQueueEnumerator.Current.Path)
numberQueues += 1
End While
Console.WriteLine(("Number of public queues: " + numberQueues.ToString()))
End Sub
End Class