I'd like to generate multiple tables with 2 rows each inside of a word document. But I want to keep these two rows together (if possible).
new KeepNext()
on the first row doesn't worknew KeepNext()
on the last paragraph of the first row doesn't worknew CantSplit()
on the table doesn't work
In all cases the second row (if too large) lands on the second page. A new CantSplit()
on the last cell ( the one with large content) avoids a break of the cell. But none of the options avoids a split of the table (rowwise).
getting all tables
You need to add a KeepNext to each row to keep them together. The XML output in document.xml should be something akin to:
This code successfully creates a table with 2 rows that will stay together across pages: