MSMQ: Problem with qInfo->PathName setting
-
Hi There. My problem is: I am able to send messages to the queue using my machines name, but am unable to do the same with IP Add. For example: qInfo->PathName = "MYCOMPUTER\\private$\\PanBQueue"; works fine... qInfo->PathName = "IP ADDRESS\\private$\\PanBQueue"; Fails... Thanks PanB
-
Hi There. My problem is: I am able to send messages to the queue using my machines name, but am unable to do the same with IP Add. For example: qInfo->PathName = "MYCOMPUTER\\private$\\PanBQueue"; works fine... qInfo->PathName = "IP ADDRESS\\private$\\PanBQueue"; Fails... Thanks PanB
Did you check the error you are getting? Please check that first?
Величие не Бога может быть недооценена.
-
Did you check the error you are getting? Please check that first?
Величие не Бога может быть недооценена.
-
I do not get any error message as such. But when I try to open the queue...i.e., qDest = qInfo->Open(MQ_SEND_ACCESS, MQ_DENY_NONE); I got an exception. Please let me know, in case you need any further details. Thanks anyway for your effort.
Please tell me whats the exception? And i hope u checked the getLastError [^]
Величие не Бога может быть недооценена.
-
Please tell me whats the exception? And i hope u checked the getLastError [^]
Величие не Бога может быть недооценена.
-
catch(_com_error &e) e.Source() -> MSMQQueueInfo e.Description() -> The queue path name specified is invalid.
I think you are using MQPathNameToFormatName, if so then DNS name is correct. It wont accept IPAddress. So i think, firstly IP address should be changed to corresponding DNS name [^]
Величие не Бога может быть недооценена.
-
I think you are using MQPathNameToFormatName, if so then DNS name is correct. It wont accept IPAddress. So i think, firstly IP address should be changed to corresponding DNS name [^]
Величие не Бога может быть недооценена.
-
More info: I want to place a message from MachineA to MachineB's Message Queue. So, I have to access the message queue on MachineB using its IP Address itself. Any pointers/suggestions will be highly appretiated. Thanks.
As i suggested earlier, get the DNS name from IPadress using gethostbyaddr API [^] And then pass DNS name with the path. Now your problem solved,isn't it?
Величие не Бога может быть недооценена.
modified on Wednesday, December 23, 2009 11:43 PM