Last post Feb 19, 2007 12:21 AM by MNF
Feb 19, 2007 12:21 AM|MNF|LINK
In Enterprise Library (v2.0) Logging Block app.config loggingConfiguration/listeners/Add element has source parameter which should corresponds to source column in EventLog for FormattedEventLogTraceListener .
I've noticed, that I a have to specify existing EventSource or create new using
EventLog.CreateEventSource . Otherwise nothing will be logged, and no any warnings will be shown that write to the event log failed.
I think it is a bug or, at least, not-documented behavior.
If I understand correctly from this article, the base System.Diagnostics.EventLogTraceListener has initializeData attribute, which creates the Event Source automatically if