docx4j is an open source (Apache v2) library for creating, editing, and saving OpenXML "packages", including docx, pptx, and xslx.
It uses JAXB to create the Java representation.
This is docx4j for Java 8. Although in principle it would compile and run under Java 6, some of its dependencies are Java 8 only. So to run it under Java 6, you'd need to use the same version of the deps which docx4j 6.x uses.
docx4j v8 is a multi-module Maven project.
To use docx4j v8, add the dep corresponding to the JAXB implementation you wish to use
You should use one and only one of docx4j-JAXB-*
is in preparation, will be based on this branch, and will require Java 11 (or possibly only 9); we're currently waiting on https://github.com/eclipse-ee4j/jaxb-ri to release a Java 11 friendly JAXB 2.4.0 to Maven Central.
Get it from GitHub, at https://github.com/plutext/docx4j
mvn clean
mvn install
Some of the tests might fail on Windows. For now, you could skip them: mvn install -DskipTests
For more details, see http://www.docx4java.org/blog/2015/06/docx4j-from-github-in-eclipse-5-years-on/
If you are working with the source code, please join the developer mailing list:
docx4j-dev-subscribe@docx4java.org
http://www.docx4java.org/downloads.html
See the Getting Started guide: https://github.com/plutext/docx4j/tree/master/docs
and the Cheat Sheet: http://www.docx4java.org/blog/2013/05/docx4j-in-a-single-page/
And see the sample code: https://github.com/plutext/docx4j/tree/master/src/samples
You'll probably want the Helper AddIn to generate code: http://www.docx4java.org/blog/2016/05/docx4j-helper-word-addin-new-version-v3-3-0/
http://www.docx4java.org/forums or StackOverflow (use tag 'docx4j')
Please post to one or the other, not both
docx4j is published under the Apache License version 2.0. For the license text, please see the following files in the legals directory:
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。