Jump to content
Changes to the Jaspersoft community edition download ×

Horizontal Filling


thiagot

Recommended Posts

Hi,

 

Is there a way to perform horizontal filling with a field?

 

Like a field $F{number} the result will be:

10 20 2 3 20 40 80

 

instead of one in each line

 

I know there is possible to divide the report in columns, but that would be a static way. if my datasource has more entries than report's columns, it would go to the next line, I dont want that

 

Is there a way to do this?

 

Ty

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

If you have only one field, you could overwrite the getFieldValue() method of the datasource class.

 

something like:

Code:

class MyDataSource extends OtherDataSource {

public Object getFieldValue(JRField jrField) {
StringBuffer data = new StringBuffer(""«»);
while(a_condition) {
data.append((String)super.getFieldValue(jrField)+ " "«»);
if(!next()) {
break;
}
}
return data.toString();
}

}

Post edited by: Alexander Merz, at: 2006/08/08 20:27

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