How do I debug a method in a .asmx Web Service

3

I have a call in my application, which goes to a WS and excuta a method and returns me. How do I debug WS?

    
asked by anonymous 25.11.2014 / 23:02

2 answers

4

To debug from Visual Studio, you must attach ( attach >) to the ASP.NET workflow ( Work Process ). I'm not with Visual Studio at the moment but I believe the following steps are:

1- Start your web application that calls the WebService. Put the breakpoint somewhere before the method in which the WebService is called.

From the Debug menu, choose Processes / Attach to Proccess .

3-Adialogboxappearsdisplayingtheprocesses.Inthelistofavailableprocesses,choosetheprocessaspnet_wp.exeorw3wp.exe.ClicktheAttachbuttontoattachtheWebServicetotheapplicationprocess.

Ifyouareindoubtaboutwhichprocesstoattach,simplyrunthe/webserviceapplicationthatVisualStudioitselfdisplaysapopup:

This link has the " Debugging a Deployed XML Web Service "explaining in more detail.

    
26.11.2014 / 12:56
1

If you have the source code of WS you can debug by the WCF Test Client from Visual Studio itself, otherwise (just make a call to consume WS) you can only simulate the method call using Soap UI. >     

26.11.2014 / 12:51