To debug AIF web services called from .NET code use the following steps:
1. On the AOS turn debugging on in the server configuration utility by marking the checkbox "Enable breakpoints to debug X++ code running on this server".
2. On the client machine turn debugging on in the client configuration utility for the Business Connector. You do this in the configuration utility by setting the Configuration Target dropdown to Business Connector (non-interactive use only). Under the Developer tab mark the checkboxes for "Enable user breakpoints to debug code in the Business Connector" and "Enable global breakpoints to debug code running in the Business Connector or client"
3. While it isn't required I would also recommend turning on debugging for the regular AX client in the client configuration utility. You do this in the configuration utility by setting the Configuration Target dropdown to the configuration your AX client uses. Then mark the debugging checkboxes.
4. In AX go to Tools > Options > Development tab. In there set the When Breakpoint dropdown to Debug mode.
5. In AX under Tools > Development tools > Debugger - this opens an empty debugging window. You can minimize this window but you need to leave it open throughout your debugging session.
6. In AX find the places in X++ code that you want to debug and set breakpoints.
7. Run your code that calls the web service. When the breakpoints are hit the empty debugging window should open with the breakpoint you made in it.
***If you are not able to hit the breakpoint after following these steps and are using a Windows Server 2008 machine you need to install KB #2251040.
How do I obtain the KB 2251040 update? I am on AX 2009 SP 1 Rollup 7 which has a higher build than the KB update. Will that be a problem?
You would not want to load the KB listed if you are on a version past that. You may also have to run the Debugger as Administrator if you are still having trouble.
Becky, everywhere I go looking for AX help (mainly aif) you're always there just putting down the facts. Huge props. Loving all your blog posts. Don't ever stop.