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

Multiline text fields with labels


lkaleta

Recommended Posts

I would like to build report which will look like this:

label 1:  text1 text1 text1

             text1 text1 text1 

label 2:  text2 text2 text2

             text2 text2 text2

 

the labels are taken from resources i18N files.

the text for labels can have multiple lines.

For now I have it work like this (it is consitent of four text fields)

label 1:  text1 text1 text1

label 2:  text1 text1 text1

             text2 text2 text2

             text2 text2 text2

Could you please give me a hint how to achive this ?



Post Edited by lkaleta at 12/31/2011 12:08
Link to comment
Share on other sites

  • Replies 8
  • Created
  • Last Reply

Top Posters In This Topic

OK, you may need to use a table element and to set the property of your testField to Stretch with overflow. You may even try to use a Table inside your table and I haven't tested it but you could put that table inside the detail band so that you have your table populated with all the data from your datasource too. This last thing is just a guess though.
Link to comment
Share on other sites

As far as I understand, table is for collections while mine is just single POJO with couple String fields (free text), integers and BigDecimals.

For mine poje I use report parameters. I do not know how can I use parameters with table.

Link to comment
Share on other sites

rpeguet thanks for your help so far!

 

ok, how can I create table with multiple rows ?

 

Lets say that I have a bean:

public class Bean {

private String a;

private String b;

private Integer c;

// getter and settter ommited

}

This single bean is only source of data for report, so I am defining 3 fields in mine report: a, b, c

 

Row 1 -> $R{a.key}, $F{a}

Row 2 -> $R{b.key}, $F{b}

Row 3 -> $R{c.key}, $F{c}

 

I do not see an option to do that.

 

Link to comment
Share on other sites

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...