The issue is when we open the report in our software, so on a server. Below you can find the jrxml for the table of contents: <?xml version="1.0" encoding="UTF-8"?><!-- Created with Jaspersoft Studio version 6.9.0.final using JasperReports Library version 6.9.0-cb8f9004be492ccc537180b49c026951f4220bf3 --><jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="table_of_contents" pageWidth="595" pageHeight="842" columnWidth="445" leftMargin="75" rightMargin="75" topMargin="75" bottomMargin="50" resourceBundle="messages" uuid="f36f080a-5efe-48e8-870b-2ff32c285b1a"> <property name="com.jaspersoft.studio.data.defaultdataadapter" value="One Empty Record"/> <property name="net.sf.jasperreports.print.create.bookmarks" value="true"/> <property name="com.jaspersoft.studio.unit." value="pixel"/> <template><![CDATA[$P{opal_style.jrtx} == null ? "opal_style.jrtx" : $P{opal_style.jrtx}]]></template> <parameter name="opal_style.jrtx" class="net.sf.jasperreports.engine.JRTemplate" isForPrompting="false"/> <parameter name="RESOURCES" class="java.util.ResourceBundle" isForPrompting="false"> <defaultValueExpression><![CDATA[$P{REPORT_RESOURCE_BUNDLE}]]></defaultValueExpression> </parameter> <parameter name="REPORT_TITLE" class="java.lang.String"> <parameterDescription><![CDATA[]]></parameterDescription> </parameter> <queryString language="SQL"> <![CDATA[]]> </queryString> <field name="label" class="java.lang.String"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <field name="pageIndex" class="java.lang.Integer"/> <field name="level" class="java.lang.Integer"/> <variable name="level2Index" class="java.lang.Integer"> <variableExpression><![CDATA[$F{level} == 1 ? 0 : ($F{level} == 2 ? ($V{level2Index} + 1) : $V{level2Index})]]></variableExpression> </variable> <background> <band splitType="Stretch"/> </background> <title> <band splitType="Stretch"/> </title> <pageHeader> <band height="15" splitType="Stretch"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <textField isStretchWithOverflow="true"> <reportElement key="" style="Title" isPrintRepeatedValues="false" x="0" y="0" width="445" height="15" isPrintWhenDetailOverflows="true" uuid="3b3c1150-4978-46cc-b832-e001eadabe3c"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> </reportElement> <textFieldExpression><![CDATA[$P{RESOURCES}.getString("zz_report.title.contents")]]></textFieldExpression> </textField> </band> </pageHeader> <columnHeader> <band splitType="Stretch"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> </band> </columnHeader> <detail> <band height="15" splitType="Stretch"> <printWhenExpression><![CDATA[$F{level} == 1 && $F{label}!=null]]></printWhenExpression> <textField isStretchWithOverflow="true" isBlankWhenNull="true" hyperlinkType="LocalAnchor"> <reportElement style="Normal" positionType="Float" x="0" y="0" width="300" height="15" isRemoveLineWhenBlank="true" isPrintWhenDetailOverflows="true" uuid="0a880c04-482b-4c1e-8723-ca74f3e2e781"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> </reportElement> <textFieldExpression><![CDATA[$F{label}]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> <textField isStretchWithOverflow="true" isBlankWhenNull="true" hyperlinkType="LocalAnchor"> <reportElement style="Normal" positionType="Float" x="415" y="0" width="30" height="15" isRemoveLineWhenBlank="true" isPrintWhenDetailOverflows="true" uuid="af2e76ef-83f0-42e2-b114-ebe997055b92"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> <printWhenExpression><![CDATA[$F{label}!=null]]></printWhenExpression> </reportElement> <textFieldExpression><![CDATA[$V{PAGE_NUMBER} + $F{pageIndex} + 2]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> </band> <band height="15"> <printWhenExpression><![CDATA[$F{level} == 2 && $F{label}!=null]]></printWhenExpression> <textField isStretchWithOverflow="true" isBlankWhenNull="true" hyperlinkType="LocalAnchor" bookmarkLevel="1"> <reportElement style="NormalItalic" positionType="Float" x="30" y="0" width="300" height="15" isRemoveLineWhenBlank="true" isPrintWhenDetailOverflows="true" uuid="2f720a50-d29b-4fc6-98f5-aeae8f3de2da"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> <printWhenExpression><![CDATA[$F{label}!=null]]></printWhenExpression> </reportElement> <textFieldExpression><![CDATA[$F{label}]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> <textField isStretchWithOverflow="true" isBlankWhenNull="true" hyperlinkType="LocalAnchor"> <reportElement style="NormalItalic" positionType="Float" x="415" y="0" width="30" height="15" isRemoveLineWhenBlank="true" isPrintWhenDetailOverflows="true" uuid="a602d02c-a342-4fd7-9838-45dd35bd0e87"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> </reportElement> <textFieldExpression><![CDATA[$V{PAGE_NUMBER} + $F{pageIndex} + 2]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> </band> <band height="15"> <printWhenExpression><![CDATA[$F{level} == 1]]></printWhenExpression> <textField isStretchWithOverflow="true" isBlankWhenNull="true" hyperlinkType="LocalAnchor"> <reportElement style="NormalBlank" x="-150" y="0" width="450" height="15" isPrintWhenDetailOverflows="true" uuid="2e919e96-dac1-49d0-976b-572c82e5cef4"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> <printWhenExpression><![CDATA[$F{label}!=null]]></printWhenExpression> </reportElement> <textFieldExpression><![CDATA["Empty line"]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> </band> </detail> <columnFooter> <band splitType="Stretch"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> </band> </columnFooter> <pageFooter> <band height="25" splitType="Stretch"> <textField> <reportElement key="" style="FooterBlue" x="0" y="10" width="100" height="15" isPrintWhenDetailOverflows="true" uuid="10c5713b-018f-4294-afbd-d37ed21b66bc"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.x" value="pixel"/> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> </reportElement> <textFieldExpression><![CDATA[$P{RESOURCES}.getString("scenarioReturn")]]></textFieldExpression> </textField> <textField> <reportElement key="" style="Footer" x="100" y="10" width="245" height="15" isPrintWhenDetailOverflows="true" uuid="e3fac7fa-d05c-448e-b2fd-26b5b63cb3a8"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.x" value="pixel"/> </reportElement> <textFieldExpression><![CDATA[$P{REPORT_TITLE}]]></textFieldExpression> </textField> <textField evaluationTime="Master"> <reportElement key="" style="Footer" x="345" y="10" width="100" height="15" uuid="becab897-8fab-4c27-819b-f58fdf0f091f"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> </reportElement> <textElement textAlignment="Right"/> <textFieldExpression><![CDATA[$P{RESOURCES}.getString("page")+" " + $V{MASTER_CURRENT_PAGE} + " " + $P{RESOURCES}.getString("of") + " " + $V{MASTER_TOTAL_PAGES}]]></textFieldExpression> </textField> </band> </pageFooter> <summary> <band splitType="Stretch"> <property name="com.jaspersoft.studio.unit.height" value="pixel"/> </band> </summary></jasperReport>