IBM Support

Birt reports formatting change in version 4.8

Troubleshooting


Problem

 Blank rows are shrunk when the pdf is generated. In Eclipse your layout can look as follows:
image-20231123155737-1
It will also appear fine in the html viewer, however, when the pdf is generated, the area consumed by a blank row is shrunk to a minimal size.  This is a problem if spacing is critical to your output. For example, if you want a larger box to allow for a signature on the printed paper. This shrinking did not happen with Birt 4.3.1, which was used up to and including Maximo 7.6.1.2.  In 7.6.1.3 we incorporated Birt 4.8 into the product.

Symptom

When you preview a report,  you can see the following for your 2 empty rows. This would be the same as in previous versions.
image-20231123160133-2
However, once you generate a pdf, the output shrinks if the row is blank.
image-20231123160215-3

Diagnosing The Problem

Note in the sample that the first row shrunk to a small size but the second row did not? This is due to the addition of an empty label to one of the cells in the second row.
image-20231123161137-4

Resolving The Problem

If you require a row size to remain constant, the easiest solution is to add a label control to one of the cells in the row. Don't enter any value for label and it remains blank. This row will not shrink in the pdf output.
In the code it will simply appear as:
                                    <label id="####"/>
If you do not have Eclipse, you can add this line yourself into the appropriate cell. If you can identify the cell within your code you add the statement in that section. You need to assign a unique label id. Pick a random 4-digit number and search the entire file for it to make sure it has not been used for any other control in the report.
Here's what the entire cell looks like in the example I have shown:
<row id="2380">
                                <property name="height">0.5729166666666666in</property>
                                <cell id="2381">
                                    <property name="borderBottomColor">#000000</property>
                                    <property name="borderBottomStyle">solid</property>
                                    <property name="borderBottomWidth">thin</property>
                                    <property name="borderLeftColor">#000000</property>
                                    <property name="borderLeftStyle">solid</property>
                                    <property name="borderLeftWidth">thin</property>
                                    <property name="borderRightColor">#000000</property>
                                    <property name="borderRightStyle">solid</property>
                                    <property name="borderRightWidth">thin</property>
                                    <property name="borderTopColor">#000000</property>
                                    <property name="borderTopStyle">solid</property>
                                    <property name="borderTopWidth">thin</property>
                                    <label id="2389"/>
This added a blank label control to the cell.  When printed to pdf this row will not shrink even if all of the other cells on the row are blank.

Document Location

Worldwide

[{"Type":"MASTER","Line of Business":{"code":"LOB59","label":"Sustainability Software"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSLKT6","label":"IBM Maximo Asset Management"},"ARM Category":[{"code":"a8m50000000CbCWAA0","label":"Reporting"}],"ARM Case Number":"TS014101850","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All Versions"}]

Document Information

Modified date:
23 November 2023

UID

ibm17082669