I am trying to configure trace listeners in my web config file for an
asp.net web service , but I seem
to be having a problem. I'm hoping someone will be able to spot what I'm
doing wrong...

It comes up with an error 'Exception in configuration section handler'

Line 38: </businessStream>
Line 39:
Line 40: <system.diagnostics>
Line 41: <switches>
Line 42: <add name="MainSwitch" value="4"/>


<system.diagnostics>
<switches>
<add name="MainSwitch" value="4"/>
</switches>
<trace autoflush="true" indentsize="4">
<listeners>
<add name="myListenere" type="System.Diagnostics.TextWriterTraceListener"
initializeData="c:\myListener.log" />
</listeners>
</trace>
</system.diagnostics>

<system.web>
<compilation defaultLanguage="c#" debug="false" />
<trace enabled="false" requestLimit="10" pageOutput="true"
traceMode="SortByTime" localOnly="true" />
<customErrors mode="RemoteOnly" />
<authentication mode="Windows" />
<authorization>
<allow users="*" />
</authorization>
<sessionState mode="InProc" stateConnectionString="tcpip=127.0.0.1:42424"
sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes"
cookieless="false" timeout="20" />
<globalization requestEncoding="utf-8" responseEncoding="utf-8" />
</system.web>

Cheers

Ollie Riches
http://www.phoneanalyser.net

Disclaimer: Opinions expressed in this forum are my own, and not
representative of my employer.
I do not answer questions on behalf of my employer. I'm just a programmer
helping programmers.

Re: Exception in configuration section handler. by Ollie

Ollie
Tue Mar 08 08:06:49 CST 2005

got it working....

You have to place the <system.diagnostics> tage after the <system.web> tag

Ollie



"Ollie Riches" <ollie.riches@phoneanalser.net> wrote in message
news:#zPGBD9IFHA.2704@tk2msftngp13.phx.gbl...
> I am trying to configure trace listeners in my web config file for an
> asp.net web service , but I seem
> to be having a problem. I'm hoping someone will be able to spot what I'm
> doing wrong...
>
> It comes up with an error 'Exception in configuration section handler'
>
> Line 38: </businessStream>
> Line 39:
> Line 40: <system.diagnostics>
> Line 41: <switches>
> Line 42: <add name="MainSwitch" value="4"/>
>
>
> <system.diagnostics>
> <switches>
> <add name="MainSwitch" value="4"/>
> </switches>
> <trace autoflush="true" indentsize="4">
> <listeners>
> <add name="myListenere"
type="System.Diagnostics.TextWriterTraceListener"
> initializeData="c:\myListener.log" />
> </listeners>
> </trace>
> </system.diagnostics>
>
> <system.web>
> <compilation defaultLanguage="c#" debug="false" />
> <trace enabled="false" requestLimit="10" pageOutput="true"
> traceMode="SortByTime" localOnly="true" />
> <customErrors mode="RemoteOnly" />
> <authentication mode="Windows" />
> <authorization>
> <allow users="*" />
> </authorization>
> <sessionState mode="InProc"
stateConnectionString="tcpip=127.0.0.1:42424"
> sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes"
> cookieless="false" timeout="20" />
> <globalization requestEncoding="utf-8" responseEncoding="utf-8" />
> </system.web>
>
> Cheers
>
> Ollie Riches
> http://www.phoneanalyser.net
>
> Disclaimer: Opinions expressed in this forum are my own, and not
> representative of my employer.
> I do not answer questions on behalf of my employer. I'm just a programmer
> helping programmers.
>
>



Re: Exception in configuration section handler. by Ollie

Ollie
Tue Mar 08 08:42:20 CST 2005

I also had to grant permissions for the 'NETWORK SERVICE' account to write
to the location question

Ollie

"Ollie Riches" <ollie.riches@phoneanalser.net> wrote in message
news:eS0$Xg#IFHA.1528@TK2MSFTNGP09.phx.gbl...
> got it working....
>
> You have to place the <system.diagnostics> tage after the <system.web> tag
>
> Ollie
>
>
>
> "Ollie Riches" <ollie.riches@phoneanalser.net> wrote in message
> news:#zPGBD9IFHA.2704@tk2msftngp13.phx.gbl...
> > I am trying to configure trace listeners in my web config file for an
> > asp.net web service , but I seem
> > to be having a problem. I'm hoping someone will be able to spot what I'm
> > doing wrong...
> >
> > It comes up with an error 'Exception in configuration section handler'
> >
> > Line 38: </businessStream>
> > Line 39:
> > Line 40: <system.diagnostics>
> > Line 41: <switches>
> > Line 42: <add name="MainSwitch" value="4"/>
> >
> >
> > <system.diagnostics>
> > <switches>
> > <add name="MainSwitch" value="4"/>
> > </switches>
> > <trace autoflush="true" indentsize="4">
> > <listeners>
> > <add name="myListenere"
> type="System.Diagnostics.TextWriterTraceListener"
> > initializeData="c:\myListener.log" />
> > </listeners>
> > </trace>
> > </system.diagnostics>
> >
> > <system.web>
> > <compilation defaultLanguage="c#" debug="false" />
> > <trace enabled="false" requestLimit="10" pageOutput="true"
> > traceMode="SortByTime" localOnly="true" />
> > <customErrors mode="RemoteOnly" />
> > <authentication mode="Windows" />
> > <authorization>
> > <allow users="*" />
> > </authorization>
> > <sessionState mode="InProc"
> stateConnectionString="tcpip=127.0.0.1:42424"
> > sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes"
> > cookieless="false" timeout="20" />
> > <globalization requestEncoding="utf-8" responseEncoding="utf-8" />
> > </system.web>
> >
> > Cheers
> >
> > Ollie Riches
> > http://www.phoneanalyser.net
> >
> > Disclaimer: Opinions expressed in this forum are my own, and not
> > representative of my employer.
> > I do not answer questions on behalf of my employer. I'm just a
programmer
> > helping programmers.
> >
> >
>
>