Convert .doc/.docx documents to .odt (Open document text) and vice versa using java.
Asked Answered
J

2

0

Is there any java library which can be used for converted Microsoft Word files (doc/docx) to Open Document Text format(.odt) formats. Free library would be preferable.

Jacobin answered 20/8, 2013 at 11:3 Comment(0)
G
0

I don't know about any libraries that do it directly, but it should be relatively easy to exact the bits you're interested from a .docx using poi:

http://poi.apache.org/

and then write them to an ODT format using ODFDOM:

http://incubator.apache.org/odftoolkit/odfdom/index.html

This should be relatively straightforward for simple documents, but if your use case calls for complex doucments containing pictures etc, this might become a LOT harder.

Anyway, hope this helps at least some ;)

Googins answered 20/8, 2013 at 11:18 Comment(0)
V
0

I believe everything you need is in this post: http://angelozerr.wordpress.com/2012/12/06/how-to-convert-docxodt-to-pdfhtml-with-java/

For instance:

JODConverter : JODConverter automates conversions between office document formats using OpenOffice.org or LibreOffice. Supported formats include OpenDocument, PDF, RTF, HTML, Word, Excel, PowerPoint, and Flash. It can be used as a Java library, a command line tool, or a web application.

Visakhapatnam answered 20/8, 2013 at 11:12 Comment(0)
G
0

I don't know about any libraries that do it directly, but it should be relatively easy to exact the bits you're interested from a .docx using poi:

http://poi.apache.org/

and then write them to an ODT format using ODFDOM:

http://incubator.apache.org/odftoolkit/odfdom/index.html

This should be relatively straightforward for simple documents, but if your use case calls for complex doucments containing pictures etc, this might become a LOT harder.

Anyway, hope this helps at least some ;)

Googins answered 20/8, 2013 at 11:18 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.