Home All Groups Group Topic Archive Search About

Creating a Custom Shared TraceListener

Author
23 Nov 2007 6:08 PM
PJ on Development
Hi,

I'm having a little bit of trouble.

I'm trying to create a shared trace listened that requires some
aditional parameters.

When I add the following line to the <sharedListeners> ...

      <add name ="TraceName"
           type="MyCustomTraceListener"
           initializeData="My Initialization Data"
MyCustomProperty="abc"  />

I get a ConfigurationErrorsException telling me that the
MyCustomProperty is not a valid configuration property.

In MyCustomTraceListener the property is decorated as follow:

    <Configuration.ConfigurationProperty("MyCustomProperty",
IsRequired:=False)> _
    Public Property MyCustomProperty() As String
        ...
    End Property

I don't know what I'm doing wrong.

Can some one, please, shed some light?

Regards,

Paulo Santos
http://pjondevelopment.50webs.com

AddThis Social Bookmark Button