Changing the source name for the error in Windows log event
am 03.04.2008 11:56:01 von ShrikantMoreUsing enterprise library, how can i get the custom source name in the windows
event log. When ever i am logging an error in windows event log, it gives the
source name as "Enterprise Library Logging". I want my custom source name
such as "MyApplication_Subsystem_Application" instead of "Enterprise Library
Logging ".
Source name would be different depending upon the application from where
the error occours.
Code in the Web.Config :
listenerDataType="Microsoft.Practices.EnterpriseLibrary.Logg ing.Configuration.FormattedEventLogTraceListenerData,
Microsoft.Practices.EnterpriseLibrary.Logging, Version=3.1.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
traceOutputOptions="None"
type="Microsoft.Practices.EnterpriseLibrary.Logging.TraceLis teners.FormattedEventLogTraceListener,
Microsoft.Practices.EnterpriseLibrary.Logging, Version=3.1.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
name="EventLoggingListener" />
listenerDataType="Microsoft.Practices.EnterpriseLibrary.Logg ing.Configuration.FormattedEventLogTraceListenerData,
Microsoft.Practices.EnterpriseLibrary.Logging, Version=3.1.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
traceOutputOptions="None"
type="Microsoft.Practices.EnterpriseLibrary.Logging.TraceLis teners.FormattedEventLogTraceListener,
Microsoft.Practices.EnterpriseLibrary.Logging, Version=3.1.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
name="Formatted EventLog TraceListener1" />
type="Microsoft.Practices.EnterpriseLibrary.Logging.Formatte rs.TextFormatter,
Microsoft.Practices.EnterpriseLibrary.Logging, Version=3.1.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
name="Text Formatter" />