Wednesday, March 30, 2016

Web Services cannot find dll's in nested bin folders

When you create a new project and use a Class Library project type, the default configuration is to put the dll's in a folder named bin/release or bin/debug depending on your current build.  Then if you add a web service (either asmx or wcf), the web service will not be able to find the dll's because they are nested.  You must change the Project Properties, Compile tab, Build Output Path to just "/bin".

If you fail to do this, when you right click on the web service, and click View in Browser, you will get a parser error saying:  Could not create type.

This is a rare problem, because most of the time, you are creating a web project type that makes this configuration for you.

No comments:

Post a Comment