steves Posted September 15, 2009 Share Posted September 15, 2009 Hi All,I am considering switching from Crystal Reports and am migrating some reports to Jasper as a test. Many of our reports use Crystal's "print at bottom of page" . My current report is actually an invoice. Invoices are printed in batches by customer. I have defined a group on the invoice number. The report is arranged with the invoice header data, bill to, ship to, logo, etc, in the group header. The detail is a subreport that displays all of the invoice line detail. The footer data, sub-total, tax, total, remittance info, etc., is in a page footer so I can force it to the bottom of the page but it should only print on the last page of a multi page invoice. I have tried to use page number == page count for a print when expression for the page footer but I created all kinds of errors. My question is should I be using the page footer, or the group footer. The page footer prints in the right place but prints on every page. The group footer prints once for each invoice but prints immediately following the details regardless of where they end on the page. What is the "best practice" to accomplish this?ThanksSteve Link to comment Share on other sites More sharing options...
svenn Posted September 15, 2009 Share Posted September 15, 2009 BTW PAGE_COUNT represent the number of records processed in the current page not the number of pages created. Link to comment Share on other sites More sharing options...
steves Posted September 15, 2009 Author Share Posted September 15, 2009 So the question changes a little to:How to comapare the page number evaluated now to the page number evaluated at the end of a group.Thanks,Steve Link to comment Share on other sites More sharing options...
walmillard Posted September 16, 2009 Share Posted September 16, 2009 Each Field element has an "Evaluation Time" property that will determin the value printed. The classic example is PAGE_NUMBER.If you have 2 fields Both Printing PAGE_NUMBER you set one to "Now" to print the current page and the other to "Report" to print the total number of pages hence you can print Page 1 of 100 using the same variable with different evaluation times. So you would need to declare variables to hold the current page and total and set the "Reset Type" then use these in your evaluation. Sould be doable.Also the "summary" band prints once as the last page of a report.Luck! 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