Note: The .Net code is extracted from a custom solution which we built to hear to MSMQ messages and then logon to AX and pass on the message to an AX API.
Step1:
Launch Vision Connector Test Application (Start => Programs => Vision Connector => Vision Connector Test Application).
Note: Make sure message queues are set properly in Send queue and Receive queue.
Launch Vision Connector Test Application (Start => Programs => Vision Connector => Vision Connector Test Application).
Note: Make sure message queues are set properly in Send queue and Receive queue.
Step2:
Launch TestVisionConnector.sln (.Net Solution) using VS 2005. Insert a breakpoint by going
Launch TestVisionConnector.sln (.Net Solution) using VS 2005. Insert a breakpoint by going
Step3:
Press F5 key inorder to initiate the debugging process. Now, a window will open and the status of the title bar for the project will show Running.
Press F5 key inorder to initiate the debugging process. Now, a window will open and the status of the title bar for the project will show Running.
Step4:
Launch Microsoft Dynamics AX and Navigate to AOT/Classes/ VCMSMQMgt as shown below:
Tip: Press “Ctrl + D” key to launch AOT (Application Object Tree) in AX.
Launch Microsoft Dynamics AX and Navigate to AOT/Classes/ VCMSMQMgt as shown below:
Tip: Press “Ctrl + D” key to launch AOT (Application Object Tree) in AX.
Step5:
Open Class VCMSMQMgt and go to the method NewMessageXML and press F9 key to insert a breakpoint.
Open Class VCMSMQMgt and go to the method NewMessageXML and press F9 key to insert a breakpoint.
Step7:
This should open a new Debugger Window as shown below:
This should open a new Debugger Window as shown below:
Step8:
Start the communication flow by sending a request from the test application i.e. by pressing the “Send Request to Queue” button shown below:
Start the communication flow by sending a request from the test application i.e. by pressing the “Send Request to Queue” button shown below:
Step9:
Automatically, the breakpoint will be hit in TestVisionConnector application. (.Net solution).
Automatically, the breakpoint will be hit in TestVisionConnector application. (.Net solution).
Step10:
Step over the code line by line by clicking the F10 key till the execution reaches the following line:
axobj.Call("NewMessageXML", InXML.xml);
axobj.Call("NewMessageXML", InXML.xml);
Step11:
Now, press F11 key to step in to AX Debug environment.
Now, press F11 key to step in to AX Debug environment.
The above steps completes one cycle of debugging through the entire communication chain between Vision connector test application to Dynamics AX routing via .Net code.
nice article. I would love to follow you on twitter.
ReplyDelete