WCF Beginner's Manual - Unable to Debug (Paste)

I am doing the following tutorial http://msdn.microsoft.com/en-us/library/ms731835%28v=vs.100%29.aspx and the program works fine. Both services and the client are in different solutions. I can start the service from one visual studio and successfully launch the client program. However, I want to do debugging. I want to enter the service code from the client code. When I try to do this, I get the following error.

"Cannot automatically go to the server. Could not connect to the server process. The debugger is already connected."

Both the client and server are console applications, and the service is slf. I also tried including debug = true in the client app.config file.

thanks

Varun

+6
source share
2 answers

There are several possible options for what you are trying to achieve:

  • As the error indicates, the client debugger cannot connect to the server process because it already received the debugger. Try starting the server without a debugger.
  • Including client and server code in the same solution, and then using RMC -> Debug -> Starting a new instance on your server and client projects
  • Starting a server process with a debugger, and then using "Debugging β†’ Attach to Processes .." to attach to the client code (it cannot be started using the debugger)

I would recommend (at least for now), putting the two in the same debugging solution. It is easier to work with it in one workspace.

+3
source

You must attach the service to the client. In debug->Attach->(devenv.exe of the VS instance where the Client is running) , go to debug->Attach->(devenv.exe of the VS instance where the Client is running) , and then start the client.

+3
source

Source: https://habr.com/ru/post/912282/


All Articles