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

Clarifying purpose of "Remove Line When Blank


rsilverns.sympatico.ca

Recommended Posts

Hey all,

 

I have a simple report using a custom data source. The data source returns an account descr, account number, value of account for each item in the result set. I organize my fields into a table like...

 

Code:

Account Descr Account # Value
Savings 12345 100000.00 (I wish)
Chequing 54321 422.00
Savings 2 666 41443.00
<Empty Row>
<Empty Row>
<Empty Row>
<Empty Row>
<Empty Row>
Total: X00.00X

 

My database is configured to have a maximum of 8 accounts so I am attempting to list them one after another stacked on top of each other as pictured above. My goal for this report, is to have the "Total: " line be sticky to the last displayed account row, so if there are only 1 accounts displayed, it would be the 2nd line down rather than 9th (as shown above).

 

In the past I have setup a custom sub-datasource object and created a sub-report to have this section grow/shrink appropriately, keeping the Total line immediately below the last Account line (would put total in the column footer area of subreport).

 

Given that there was a guaranteed number of accounts (8) I am hoping to simplify my design by not having to introduce a subreport. To do this, I tried grouping each row of this above table and then choosing the "Remove Line When Blank" option for all the fields. I also setup the fields to be blank when null, so "null" doesn't get printed for the rows that have no account. My thinking was that the Total line would be moved upwards to reflect each account line that was removed because the entire line was blank. But when I produced the report, the Total line was still 8 rows down from the top of the values. I also tried to change "Total:" positioning to be float/relative to bottom and also each row to be float.

 

My question is, am I mis-interpreting the functionality of "Remove Line When Blank", or is there additional steps I must take to acheive this? As I said, I can make it happen using a sub-report but would like to understand this Jasper feature properly for simple instances like this.

 

Thanks!

 

Rob

 

Post edited by: rsilver@bfm.bm, at: 2006/09/22 12:22

Post edited by: rsilver@bfm.bm, at: 2006/09/22 12:22

Link to comment
Share on other sites

  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

The report isn't structured with any other elements in the vertical space... is there a global report option that should be set? My elements touch... i.e. row 4 overlaps row 5 by 2 pixels for spacing reasons.. would this cause the issue? I would post the report, but a lot of the fields, SQL Query etc. is confidential. :(
Link to comment
Share on other sites

So I was creating a simplified version and it did in deed shrink up the missing sections. So it must be something in my report design I am not thinking of.

 

I will try to figure out the issue by making the two reports "meetin in the middle" so to speak and will post when I solve the issue.

 

 

Thanks for the input!

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