I´m trying to read a table from a Word document that have merged cells but I have some problems.
//////////////////////////////////Code//////////////////////////////
if (child.getNodeType() == NodeType.TABLE)
{
Table table = (Table)child;
final NodeCollection rows = table.getChildNodes();
for (int x = 0; x < rows.getCount(); x++)
{
Row row = (Row)rows.get(x);
final NodeCollection columns = row.getChildNodes();
for (int y = 0; y < columns.getCount(); y++)
{
Cell cell = (Cell)columns.get(y);
System.out.println(cell.getCellFormat().getHorizontalMerge());
}
}
}
//////////////////////////////////Code//////////////////////////////
The horizontal merge of every cell is 0 --> CellMerge.NONE constant.
I would like to know that is something wrong with that, or there is another way to know if every cell of a table has merged horizontally with others of the same row.
Thank you,
Samuel