I have a server set up that uses a PHP COM to create the "MSMQ.MSMQQueueInfo" object and then as it's PathName is set to ".\private\queue".
That works fine for the local queue (named "queue").
After researching online I was able to figure out if I want to queue a message to a remote location of an MSMQ, it's PathName needs to look something like FormatName:Direct=TCP:[ip]\\private$\\[queuename]
$msgQueueInfo = new COM("MSMQ.MSMQQueueInfo") or die("Couldn't create");
$msgQueueInfo->PathName = "FormatName:Direct=TCP:10.0.0.8\private$\queue";
$msgQueue = new COM("MSMQ.MSMQQueue") or die("Couldn't create");
$msgQueue = $msgQueueInfo->Open(2, 0);
Each time I try to run my code above I get the following error message "Source: MSMQQueueInfo
Description: The queue path name specified is invalid."
It queues the message successfully to the local queue if the path is set to ".\private$\queue" but why does it not take the remote queue path that I provide? Anything wrong with my code? Anything I have to enable? Anything I'm missing?