Jump to content
We've recently updated our Privacy Statement, available here ×

Subreport doesn't float


Recommended Posts

By: Tom Geyzen - tomgeyzen

Subreport doesn't float

2002-12-11 03:07

Hi,

 

I'm having a problem with the positioning of a subreport : it always showes up at the specified y coordinate hence ignoring positionType="Float".

This is the xml :

 

<staticText>

<reportElement x="0" y="40" width="555" height="60" forecolor="#111111" positionType="Float"/>

<textElement textAlignment="Center" lineSpacing="Single">

<font reportFont="Arial_Bold" size="14"/>

</textElement>

<text>Message Content</text>

</staticText>

<textField isStretchWithOverflow = "true">

<reportElement x="10" y="65" width="500" height="100" isRemoveLineWhenBlank="true"/>

<textElement textAlignment="Left" lineSpacing = "Single">

<font size="8" />

</textElement>

<textFieldExpression class="java.lang.String">$F{PAYLOAD}.replace('r', '')</textFieldExpression>

</textField>

<rectangle>

<reportElement x="0" y="65" width="555" height="100" mode="Transparent" positionType="Float"/>

<graphicElement stretchType="RelativeToTallestObject"/>

</rectangle>

 

<!--The subreport with the hit details-->

<subreport isUsingCache="false">

<reportElement x="0" y="150" width="555" height="1" backcolor="#FFFFDD" positionType="Float" isPrintWhenDetailOverflows="true"/>

<subreportParameter name="Id">

<subreportParameterExpression>

$F{PK}

</subreportParameterExpression>

</subreportParameter>

<connectionExpression>

$P{REPORT_CONNECTION}

</connectionExpression>

<subreportExpression class="java.lang.String">

"SUB.jasper"

</subreportExpression>

</subreport>

 

Any ideas anyone ??

 

tia

 

tom

 

 

 

 

By: Teodor Danciu - teodord

RE: Subreport doesn't float

2002-12-11 08:38

 

Hi,

 

Your subreport overlaps the above text field.

It is placed at y="150", but the text field goes

to the 65 + 100= 165

 

Your subreport should be at y="166" if you want

it to float after the text field.

 

I hope this helps.

Teodor

Link to comment
Share on other sites

  • Replies 0
  • 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...