Hi all,
I just recently built the latest version (which is several years old I think) version of log4cxx and am trying to write a log file to the user APPDATA path:
C:\Documents and Settings\%user%\Application Data\Logs\Application.log
but I can't seem to get the configuration right:
log4j.rootLogger=DEBUG, A1
log4j.appender.A1=org.apache.log4j.RollingFileAppender
log4j.appender.A1.layout=org.apache.log4j.PatternLayout
log4j.appender.A1.layout.ConversionPattern=%5p [%t] (%F:%L) - %m%n
log4j.appender.A1.File=${APPDATA}\\Logs\\Application.log
log4j.appender.A1.DatePattern='.'yyyy-MM-dd
log4j.appender.A1.MaxBackupIndex=10
This log file will end up in 'C:\Logs\Application.log' instead of the path I intended. The problem seems to be that it doesn't resolve the environment APPDATA which is definitely defined on a WinXP box. Does anyone know if there's something wrong with my configuration?
Thanks in advance!