I have got windows 2000 workstation installed machine. When I try to execute the following code to create a queue, it does not create the queue(no error!). Any solution to this?



On Error GoTo myer
Dim qi As New MSMQQueueInfo
Dim x

On Error Resume Next
qi.PathName = ".\" & txtQueueName
Set Q = qi.Open(MQ_SEND_ACCESS, MQ_DENY_NONE)
If Not (Q Is Nothing) Then
If Q.IsOpen Then
MsgBox "Queue opened!"
Exit Sub
End If
End If
'create queue
x = MsgBox("Queue not found!" & vbCrLf & "Do you want to create?", vbYesNo)
If x = vbNo Then
Set Q = Nothing
Exit Sub
End If
qi.Create
MsgBox "Queue created!"
Exit Sub
myer:
MsgBox Err.Description