0

I'm trying to make a private Queue in a external pc to send messages. I've writed the code to send and recive messages in a queue on my own pc and works fine. But i dont really understand very well how to make it on a remote pc. In this line:

var queue = new MessageQueue(@"FormatName:DIRECT=OS:mymachine\MyQueueQueue")

Dont know what "FormatName:DIRECT=OS:mymachine" represents and don't found that information on Microsoft documentation. Where should a put the ip of the external pc?

  • Did you check this solution here? https://stackoverflow.com/questions/6308668/writing-to-a-remote-msmq – Carlos Oliveira Jul 15 '20 at 15:18
  • MSMQ is [thoroughly documented](https://learn.microsoft.com/en-us/previous-versions/windows/desktop/msmq/ms711472(v=vs.85)) going back to the early 2000s. The name of the remote PC is already there - it's `my machine`. The form `server\resource` is common in Windows, whether it refers to file shares, queues, mutexes or any other type of resource – Panagiotis Kanavos Jul 15 '20 at 15:24
  • Queue path names [are documented here](https://learn.microsoft.com/en-us/previous-versions/windows/desktop/msmq/ms706083(v=vs.85)). You'll have to admit MSMQ documentation is only 100 times better than the current documentation. Back then there was enough time to thoroughly document a feature in the `About` chapter, provide full usage instructions and examples in the `Using` chapter and a detailed reference in the `Reference` chapter. Printing all this out would produce a small book – Panagiotis Kanavos Jul 15 '20 at 15:26
  • Ok, i really appreciate your answers. Have readed all the docs you recomended to me. And have one last question. I've understand that i should use TPC instead of OS, but i don't know if should put the private or public IP in the path, and if it have to be like " http : //myip" (because i readed some developers writing it in that format) – jonnamartiin Jul 16 '20 at 01:11

0 Answers0