Home:ALL Converter>JasperReports: merge cells exporting to xlsx

JasperReports: merge cells exporting to xlsx

Ask Time:2012-03-01T13:59:58         Author:user1241900

Json Formatter

I have a report with text field and this text can be long and it is wrapped. When I export report to .xls from JasperReports it is ok with this cell - i get wrapped text in one cell. But when I export to .xlsx JR adds one more excel row after row with wrapped text and merges wrapped cell with cell below.

The result for .xls import is:

XLS import result

and the result for .xlsx import is:

XLSX import result

I have tried different options of JR export - no result (I put this options into report, not into config files, may be this is important?) JasperServer version is not the latest? may be 3.x

Author:user1241900,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/9511353/jasperreports-merge-cells-exporting-to-xlsx
Jacob Schoen :

The reason for that is the cell that is wrapping is increasing its height to fit the text, while the other cells in the same row are not doing the same thing. You should try setting the Stretch Type to Relative to Tallest Object and see if that helps.\n\nAs far as why it happens on xlsx and not xls, I don't have a clue.",
2012-03-06T19:07:19
ExQSays :

I found that expanding the width of the entire report and shifting cells to the right of the area where the merge happens cleaned it up for me. The columns where the merge happened was reduced to 0 in width and empty when I ran the report again. If you don't mind the extra columns being there as they are all but invisible then this solution is confirmed to work. \n\nYou should be able to do this using the rows as well but expanding the height of the report and leaving that area blank but moving everything else down a cell in size.",
2014-11-11T21:08:15
yy