Hi All,
I want to route the posting documents through MSMQ. I am able to create the Write and Read Queue. The problem that i am facing is, when sending a message to MSMQ it's sent from the client's machine and to the local MSMQ client installed on the client's machine.
How can i trigger creation of this Queue from NAS as soon as user clicks on the Post button from Nav Client??? this will help me in installing MSMQ server on NAS server only and not on the clients..
Any alternative method for this???
Please help.....
0
Comments
What DLL are you using with the queues ???
You can try to send the documents directly to the server's queue.
I get it using CPHandler DLL (Navision uses this to manage commerce portal). This DLL's functions, allows you to pass a windows registry path as a parameter to know where the queue is.
You can add a reference in Windows registry to a queue stored in the server and when you post the document the queue used will be th servers queue. Now you can use NAS to retrieve the document from a queue and save it in a directory.
Example:
My servers's queue is MYQUEUE
I added in windows registry this key
In LOCAL_MACHINE\SOFTWARE\QUEUES\SERVERQUEUE
The key is Direct=OS:Server\Private$\MYQUEUE
In Navision I declared an automation (MYQUEUES) using CPHandler.
And a XML Doc (for example, it works with file variables)
IF ISCLEAR(MYQUEUES) THEN
CREATE(MYQUEUES);
IF ISCLEAR(XMLDocOUT) THEN
CREATE(XMLDocOUT);
XMLDocOUT.load('c:\MyXML.xml');
Cola.SendToLabel('MYQUEUES',XMLDocOUT,1,0'SOFTWARE\QUEUES\SERVERQUEUE',FALSE);
This instruction, send the doc to the queue referenced in this registry path with the name MYQUEUES, in this case to servers queue
I think this can help you
Bye
RIS Plus, LLC
One more query ... how can i make MSMQ to wait before sending the second, only once some codeunits are successfully run for the first message.