4

I am working on a DLL that a webservice I have uses, I added some new code and would like to compile and debug into it via an NUnit testing suite. The steps I have taken are.

  1. Write my code in Visual Studio 2008 with the output directory pointing to my applications bin directory (C:\Program Files\etc...).

  2. When I launch my webservice process and attach to it, I get the warning that my program was built without debug information, I found that if I copied the .pdb files in the the C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\... directory then I could avoid warning but still not hit my code section.

  3. I stopped my application, re-built my DLL's, and re-started the web application.

  4. Upon further inspection, I noticed that when I stopped my application via. process explorer and deleted the sub-directory under the Temporary ASP.NET directory, then when I restarted my process the sub-directories get re-created, however they do not contain the new DLL's that I had just previously built but an older version of the DLL's, and no PDB files either.

To sum it up my question is how do I get Visual Studio to both build and update the DLL's in the temporary ASP.NET directory? For more kudo's how do I get Visual Studio to automatically copy the PDB files to the same temporary directory without any batch assistance?

Ideally I would like to avoid this automatic copying of my DLL's to the temporary directory, but through my searching today I could not find any suitable way to do this as the ASP internals are quite out of my control.

NOTE: I have the shadow copy feature on NUnit disabled when I hit my webservice via an external executable.

wfoster
  • 781
  • 10
  • 23
  • Make sure the build process has rights to the folder. – Esteban Araya Jun 27 '11 at 22:22
  • They don't get built into this folder, they get built into the `C:\Program Files\MyApp\Bin` folder, the ASP.NET internals copy it there when the application is started. – wfoster Jun 27 '11 at 22:24
  • Do you have the optimizeCompilations flag set to true? I had a similar issue : http://stackoverflow.com/questions/6201447/iis-caching-project-reference-binaries – Matt Evans Jun 28 '11 at 07:33

1 Answers1

0

Figured this out, needed to build into the ASP.NET Websites bin directory in order to get new DLL's. Changed output paths from C:\Program Files\MyApp\Bin to C:\Program Files\MyApp\MyWebService\Bin, this seemed to solve the issues I was having and the new DLL's get copied and all the debugging works.

Cheers!

wfoster
  • 781
  • 10
  • 23