How to debug X++ web service class method

Hi everyone,

We are using X++ custom service to do server side logic and we expose them as web services for front end use. Right now, I have problems to put a break point the web service class method. Does anyone have good advice? I mean, sometimes I just want to make sure the method is being executed, but if I use

Debug::assert(false), it’s not working

Info() doesn’t work either, I guess it’s the case as the class is at server side, and not front end component.

I just want to have a way to see the method execution.

Thank you,


Services run in CIL, therefore you have to use Visual Studio to debug them. The X++ debugger is useless for this purpose.

Open your class in Application Explorer in Visual Studio, set a breakpoint, attach the debugger to the AOS process and run your service.

(Question moved to the Developer forum.)

Thank you for your reply, Martin. I am using VS2010 now,and located the Service class we wrote, however, after I use Debug > Attach to process > find the Ax32Serv.exe

I am having problem hit the break point that I put, the Solid Red Dot automatically turned into a Red Circle one with a yellow rectangle at the the right hand corner, when I use mouse to hover over, it says “The breakpoint will not currently be hit. No symbols have been loaded for this document”

But this method is supposed to be the method that the Web service operation is going to use, I checked multiple times.

Can you help a little more? picture attached.

Thank you,


Never mind, Martin, I found the reason. It turns out “When we use Visual Studio to debug any code that runs in Common Intermediate Language ﴾CIL﴿, make sure that the Enable Just My Code field is cleared. To find this field in Visual Studio, click Tools > Options > Debugging.”

Listed at