This project is read-only.

WCF Web.config error VS Debug

Feb 6, 2011 at 10:13 PM

WSCF is a great time savior when it comes to generate the WSDL and the DataContract out of the .XSD files. i am using the latest version of the framework and i

really have dificulties generating a working service when i merge the web.config and the output.config i was looking so much forward to see how this framework did in regards

to build fast wcf services because i was going to suggest to a customer of mine to use this framework as their standard to do things in regards to WCF.

But is does not matter how simple the service look like (i am using the VB.Net template because that is what they use at my customers to make their WCF services)

i can make the wsdl, great, datacontract generation (no problem), generating the skeleton for the service also great !!, but is does not matter how i merge the web.config and the output.config

file whe i try to browse the service in debug mode to see it running (i am using by default the "Visual Studio Development Server") i get the following error:


The type '', provided as the Service attribute value in the ServiceHost directive could not be found.


i have tried to both stop using the development server, and making a virtual directory in IIS to host the service and i still get the same error. anyone has encountered the same issue ?

any ideas what is going wrong ?

I apreciate some comments

Feb 7, 2012 at 8:34 PM

I've run into the same problem with wscf.Blue and VB.NET projects.  It looks like there is a problem/bug in the way the .SVC file is generated because it is missing the Project Name in the Service attribute, so the service Type can't be found.

Luckily, there is a simple workaround for this issue.

Add the project name to the service attribute in the generated .SVC file
The format is ProjectName.Namespace.ClassName

For example, change:
<%@ ServiceHost Service="Namespace.Service.SampleWCF" %>

<%@ ServiceHost Service="ProjectName.Namespace.Service.SampleWCF" %>


There is another workaround related to this issue.  When displaying the .SVC helper page, you may see a message "Metadata publishing for this service is currently disabled".  This usually shows up when you don't have a MEX endpoint defined.  However, even after you add the necessary settings for the MEX endpoint, you may still see this message.

It looks like there is also a problem with the way the output.config settings are generated, because the service name attribute is missing the Project Name as well.

To fix this, add the Project Name to the the service name attribute in the web.config:
<service name="Namespace.Service.SampleWCF">

<service name="ProjectName.Namespace.Service.SampleWCF">

thinktecture folks, can you look into these problems with VB.NET projects?

Feb 15, 2012 at 1:09 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Feb 15, 2012 at 1:32 PM

The work item above has been completed and will be included in the next update. I would like to add a few more bug fixes before releasing. Thanks for reporting the issue.