I am using BIRT 4.4.1 in eclipse for report generation.
我在eclipse中使用BIRT 4.4.1来生成报告。
I would like to wrap my text of Table Header, it works fine in webviewer but when i exported to excel the table cell text is in a single line, and also the text is overflowed. I dont want to make the cell width equal to the content, I would like to wrap the text based on its container width.
我想包装我的表头文本,它在webviewer中工作正常,但是当我导出到excel时,表格单元格文本在一行中,并且文本也溢出。我不想让单元格宽度等于内容,我想根据容器宽度包装文本。
I have set the cell width and label whitespace property as auto. is it correct, or what do i do to make it work in exported excel report?
我已将单元格宽度和标签空白属性设置为auto。它是正确的,或者我该如何使它在导出的Excel报告中工作?
In Webview
在Webview中
After exported, Excel view
导出后,Excel视图
1 个解决方案
#1
4
In 4.4.2 export as XLS (not xlsx). As a workaround you can also add a line return within the text and that will appear correctly when you export to xlsx.
在4.4.2中导出为XLS(不是xlsx)。作为一种变通方法,您还可以在文本中添加换行符,并在导出到xlsx时正确显示。
A third option that works with xlsx output is to select the text box in the cell, and in General Properties set the Whitespace to Preformatted. Then, either set the header cell size to a height that covers the required text OR in general properties of the entire report, set the layout to Auto Layout.
与xlsx输出一起使用的第三个选项是选择单元格中的文本框,并在“常规属性”中将“空白”设置为“预格式化”。然后,将标题单元格大小设置为覆盖所需文本的高度或在整个报表的常规属性中,将布局设置为自动布局。
#1
4
In 4.4.2 export as XLS (not xlsx). As a workaround you can also add a line return within the text and that will appear correctly when you export to xlsx.
在4.4.2中导出为XLS(不是xlsx)。作为一种变通方法,您还可以在文本中添加换行符,并在导出到xlsx时正确显示。
A third option that works with xlsx output is to select the text box in the cell, and in General Properties set the Whitespace to Preformatted. Then, either set the header cell size to a height that covers the required text OR in general properties of the entire report, set the layout to Auto Layout.
与xlsx输出一起使用的第三个选项是选择单元格中的文本框,并在“常规属性”中将“空白”设置为“预格式化”。然后,将标题单元格大小设置为覆盖所需文本的高度或在整个报表的常规属性中,将布局设置为自动布局。