0

I using docx4j to generated a docx from html string, works great but the tables broken when the page skip.

Table broken

This the code.

WordprocessingMLPackage wordMLPackage = WordprocessingMLPackage.createPackage();

XHTMLImporterImpl XHTMLImporter = new XHTMLImporterImpl(wordMLPackage);

//File is a htmlStringFile 
wordMLPackage.getMainDocumentPart().getContent().addAll(XHTMLImporter.convert(file, null) );

File fileDos = new File(urlWord);

I´m using a docx4j 8.3.2 with Java 8.

Somebody know how to change all properties in the general document ? Example : space between paragraph, space after the line,

Another problem, in some case the table cell add diferent space between cell. I don´t know why

cell add diferent space

MartinGam
  • 1
  • 1
  • You mean when a table cell contains enough content to flow over onto the next page? Can the problem be reproduced with a simple 1x1 table? – JasonPlutext Apr 29 '22 at 19:57
  • When the tables broken in the page break, the tables properties in word.exe set "specify height", how to dissabled that property in docx4j ?? – MartinGam May 04 '22 at 20:46
  • @JasonPlutext when the cell contains enough text and go to the next page, the table it broken. I see in word.exe it add that property ""specify height" how to set this in docx4 ? It´s posible ? – MartinGam May 04 '22 at 20:51

0 Answers0