So I'm having an intense amount of trouble trying to debug a wcf service, and could use some help. The service I'm writing is in C#, Visual Studio 2010, and is part of an existing service my company has in one of our client's projects. I'm using WCFTestClient to connect to the service when i debug it locally. Whenever I first open up visual studio and debug the service in question it works fine, but if I make changes to the code and need to rebuild, I'm getting the following error:
Unable to copy file "obj\Debug\Application.DataAccess.dll" to "bin\Debug\Application.DataAccess.dll". The requested operation cannot be performed on a file with a user-mapped section open.
The only way I've been able to work around this issue is to close visual studio and reopen it, which is rather time consuming and annoying to do every time I make a change. I've tried cleaning the solution and rebuilding, but I get the same error. I've even opened up Process Explorer to try and find what's using the dll, but the only thing is FxCopCmd.exe which is part of visual studio.
Does anyone have a better way of debugging wcf services locally, or have an idea of how to prevent or resolve the above error? Any help is greatly appreciated, thanks.