Comments (5)
It's a problem with POI, please post your question to POI forum.
from xdocreport.
looking at the stack trace of the exception, it seems more to me that it is an undefined dependency of package org.apache.poi.xwpf.converter.pdf
which is one of the XDocReport packages not POI:
java.lang.NoClassDefFoundError: org/apache/poi/xwpf/usermodel/IRunBody
at org.apache.poi.xwpf.converter.pdf.PdfConverter.doConvert(PdfConverter.java:55)
at org.apache.poi.xwpf.converter.pdf.PdfConverter.doConvert(PdfConverter.java:38)
at org.apache.poi.xwpf.converter.core.AbstractXWPFConverter.convert(AbstractXWPFConverter.java:45)
at fr.opensagres.xdocreport.converter.docx.poi.itext.XWPF2PDFViaITextConverter.convert(XWPF2PDFViaITextConverter.java:67)
at fr.opensagres.xdocreport.document.AbstractXDocReport.convert(AbstractXDocReport.java:713)
at XdocVelocityMap.main(XdocVelocityMap.java:48)
Caused by: java.lang.ClassNotFoundException: org.apache.poi.xwpf.usermodel.IRunBody
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 6 more
unfortunately XDocReport maven packages miss lots of such dependency definitions.
from xdocreport.
as I suspected the problem was wrong dependency, the docs say poi-ooxml v 3.9 but the code needs at least v 3.10.1, I used 3.11 successfully. so I would also update the docs
from xdocreport.
Doc is out of date for the version. I think it's a bad idea to set the version in the doc, because we must synch the doc with maven pom. I think it's better to set a link to the pom to know the version of POI
from xdocreport.
Actually a proper maven definition includes all the dependencies a package needs, so this (and all other packages needed) should have been a defined dependency of one of XDocReport packages which implements main Docx to PDF conversion.
from xdocreport.
Related Issues (20)
- itext7 support HOT 1
- Chinese numbering list can not render correctly
- Image replacement not working on specific environment HOT 2
- Velocity 2.3 say that XDocReport use a lot of configuration key that have been renamed
- Replace dependency com.lowagie:itext:2.1.7 with OpenPDF latest version HOT 2
- Not compatible with OpenPDF 2.0.0 - Runtime error: NoSuchMethodError void fr.opensagres.poi.xwpf.converter.pdf.internal.elements.StylableDocumentSection$SectionPdfPTable.addCell HOT 1
- NullPointerException for getText method of ListItemContext class HOT 3
- Publish version with poi 5.2.5 support HOT 4
- Apache POI document to PDF with table borders creates PDF with texts in cells positioned too low in the cells HOT 9
- illegal reflective access while using default example HOT 1
- Release date of 2.0.5? HOT 3
- there is a error when use fr.opensagres.poi.xwpf.converter.pdf-gae convert word to pdf HOT 2
- Conversion error on docm files
- Join table with freemarker
- text is lost when word is transferred to pdf! HOT 1
- Is repeating bullet points possible HOT 1
- <w:pict> images are not replaced in DOCX template
- OpenPDF converter fails with java.lang.NoSuchFieldError: list HOT 8
- missing elements when converting ODT text file to PDF HOT 1
- Velocity Template Injection
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xdocreport.