You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4net-dev@logging.apache.org by KennethLam <ki...@hotmail.com> on 2008/12/17 23:57:10 UTC
Logging seperated by date
I am currently using .Net config file to hold the log4net information.
I would like to know how can I modify the current code I have below, so that
it can create a seperate log file each day.
Thanks for help
<log4net>
<appender name="LogAllToFile"
type="log4net.Appender.RollingFileAppender">
<file value="CMSAPI.log" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="10" />
<staticLogFileName value="true" />
<layout type="log4net.Layout.PatternLayout">
<header value="[Start Log]" />
<footer value="[End Log]" />
<conversionPattern value="%newline %-5p %d %5rms %-22.22c{1}
%-18.18M - %m%n" />
</layout>
</appender>
<root>
<priority value="ALL" />
<!-- ALL, DEBUG, INFO, WARN, ERROR, FATAL, OFF-->
<appender-ref ref="LogAllToFile" />
</root>
</log4net>
--
View this message in context: http://www.nabble.com/Logging-seperated-by-date-tp21063457p21063457.html
Sent from the Log4net - Dev mailing list archive at Nabble.com.