Search code examples
javadocxdoc

How to open .doc or .docx file and check text format using java


I want to open a .doc (or .docx) file by java and check font-family of some part of text, font-size of some part of text, tables and description of tables, right indent, left indent etc.(like this image)

enter image description here

Is there any library and .jar file for this in java? How can I use it for my purpose?


Solution

  • You can take a look at Apache POI. It is a powerful library for creating and editing microsoft office documents. But if you need only to check some parameters in doc or docx you can use docx4j