> I had to tweak the code a bit but now it works like a charm. Thanks for
getting me on the right track. You made my
> day. I'll post my solution below for others. This block sits in a servlet.
I tried to run this code but it's not working in my case. I'm getting the same
error as when I tried to do it on my own.
java.io.FileNotFoundException: WEB-INF\logs\exceptions.log
Java code is exactly as yours and my properties file:
# REL_PATH=C:\\workspace\\msz\\web\\
log4j.logger.pl.akonet.framework.Servlet=DEBUG, EXCEPTIONS
log4j.appender.EXCEPTIONS=org.apache.log4j.DailyRollingFileAppender
log4j.appender.EXCEPTIONS.DatePattern='.'yyyy-MM-dd'.log'
log4j.appender.EXCEPTIONS.File=${REL_PATH}WEB-INF\\logs\\exceptions.log
log4j.appender.EXCEPTIONS.layout=org.apache.log4j.PatternLayout
log4j.appender.EXCEPTIONS.layout.ConversionPattern=%d{HH:mm:ss dd-MM-yyyy} %-5p
@ %C{1}:%M:%L - %m%n
When I uncomment first line everything works fine. I checked in debuger that
REL_PATH key is present in props when invoking PropertyConfigurator.
configure(props). What is going on?
Best regards,
Konrad Billewicz
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]