System.Configuration.ConfigurationErrorsException raised

S

Stephane Guerin

I've build a small sample WCF server (.exe). I'm using app.config to set it
up. When I start the application, I receive multiple first chance exception:
System.Configuration.ConfigurationErrorsException occurred
Message="This element is not currently associated with any context"
Source="System.Configuration"
BareMessage="This element is not currently associated with any context"
Line=0
StackTrace:
at System.Configuration.ConfigurationElement.get_EvaluationContext()
InnerException:

My app.config is:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.serviceModel>
<services>
<service
name="Zetec.Core.MessagingService"
behaviorConfiguration="MessagingServiceBehavior">
<host>
<baseAddresses>
<add
baseAddress="http://localhost:14899/ServiceModelSamples/Service"/>
</baseAddresses>
</host>
<endpoint address="MessagingService"
binding="wsDualHttpBinding"
contract="Zetec.Core.IMessagingService" />
<endpoint
address="net.pipe://localhost/servicemodelsamples/service/MessagingService"
binding="netNamedPipeBinding"
contract="Zetec.Core.IMessagingService" />
</service>
</services>
<!--For debugging purposes set the includeExceptionDetailInFaults
attribute to true-->
<behaviors>
<serviceBehaviors>
<behavior name="MessagingServiceBehavior">
<serviceMetadata httpGetEnabled="True"/>
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
</configuration>

The exception does not contain any information to help me debug this. I
have 2 questions:
- What is the error in my app.config?
- How do you debug this kind of exception? I don't have any clue where to
look for.

Thank in advance
--
Stephane Guerin
 

My Computer

Top