0

I'm writing a simple program with docx4j but getting

java.lang.NoSuchMethodError: org.apache.log4j.Logger.getAllAppenders()

I do have log4j 1.2.15 installed (listed in docx4j's dependencies). Has anyone encountered the same problem?

Hieu Phan
  • 581
  • 3
  • 7
  • 14
  • Check again that your log4j jar is on your classpath. Otherwise, tell us more about your environment, and how you are starting your program. – JasonPlutext Jul 05 '13 at 23:54

1 Answers1

0

I managed to fix this issue by configuring docx4j.properties file:

# If you haven't configured log4j yourself
# docx4j will autoconfigure it. Set this to true to disable that
docx4j.Log4j.Configurator.disabled=true
Hieu Phan
  • 581
  • 3
  • 7
  • 14