thiagot Posted August 2, 2006 Share Posted August 2, 2006 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 More sharing options...
Alexander Merz Posted August 9, 2006 Share Posted August 9, 2006 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 More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now