Tuesday

Root cause of ServletException.java.lang.NoClassDefFoundError: org/openxmlformats/schemas/drawingml/x2006/main/ThemeDocument

BUG:
While i was trying to read uploaded excel by apache poi i got following error:
   Workbook wb = WorkbookFactory.create(new FileInputStream(filename));

 Error:    Root cause of ServletException.java.lang.NoClassDefFoundError:           org/openxmlformats/schemas/drawingml/x2006/main/ThemeDocument

FIX:
I downloaded poi-ooxml-schemas.jar and add it to classpath.
You can download the jar from here.

No comments:

Post a Comment