Jump to content
Changes to the Jaspersoft community edition download ×

DETAIL BAND - SUBSTRING VARIABLE NOT PRINTED


cesare.brizio

Recommended Posts

In the detail band of my report, I have to display a substring extracted from a string field.

The field $F{GIO} is always displayed and printed, my substring variable TRENTASEIESIMO_CAR, with an expression like:

$F{GIO}.substring(36,36)

is never displayed, no matter how I set the available options (like reset group and the such). I tried to put it in different bands like group and report footer - to no avail, it gets NEVER displayed, contrary to other variables I defined containing group totals, that work fine.

 

Why this particular detail substring semems not to work?

What did I miss??

 

Thank you very much

 

Cesare Brizio

 

 

====================================

variable declaration

====================================

<variable name="TRENTASEIESIMO_CAR" class="java.lang.String" resetType="None" calculation="Nothing">

<variableExpression><![CDATA[$F{GIO}.substring(36,36)]]></variableExpression>

<initialValueExpression><![CDATA[$F{GIO}.substring(36,36)]]></initialValueExpression>

</variable>

 

====================================

textfield tag in the detail section

====================================

 

<textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" >

<reportElement

x="97"

y="82"

width="65"

height="18"

forecolor="#000000"

backcolor="#FFFFFF"

key="textField-1"/>

<box topBorder="None" topBorderColor="#000000" leftBorder="None" leftBorderColor="#000000" rightBorder="None" rightBorderColor="#000000" bottomBorder="None" bottomBorderColor="#000000"/>

<textElement textAlignment="Left" verticalAlignment="Middle">

<font fontName="Arial Narrow" pdfFontName="Helvetica" size="8" isBold="false" pdfEncoding ="Cp1252"/>

</textElement>

<textFieldExpression class="java.lang.String"><![CDATA[$V{TRENTASEIESIMO_CAR}]]></textFieldExpression>

</textField>

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...