On my previous post about Error Logging Modules & Handlers (ELMAH), I only listed to log the file in SQL database. Now, I just discovered that we can also log the file into XML format by:
- download the XML version of add-on from ELMAH GotDotNet webspace;
- place XmlErrorLog.dll file into your web application bin directory;
- edit the web.config file to point to the new provider. If you are using connection string, remove it and replace with ErrorLogPath attribute which should point to the physical location where the logs are saved, see the sample below:
<errorLog
type="GotDotNet.Elmah.XmlErrorLog, GotDotNet.Elmah.XmlErrorLog"
LogPath="C:\Inetpub\wwwroot\wdd\errorlog" />
download XmlErrorLog provider for ELMAH 1.0 here