The Mistake
I have made many reports. It began with Crystal Reports (because it was free, bundled with Visual Studio 2008), then Jasper Reports (because Crystal Report no longer bundled with Visual Studio 2010), and then finally Telerik Reporting (because integrating Jasper Reports to ASP.NET is such a whack-job, I still don’t dare to share my code, even it’s already 5 years passed).
I always thought that I made the best reports in the world 😀 But recently I realized that my reports are ugly. Just look at below example:
Ugly right? Do you agree that the signature boxes should be shifted all the way down to the bottom of the page?
Let’s look how I structured my report:
Apparently I put the signature boxes inside Report Footer Section.
Q: Why didn’t you put the box within Page Footer Section?
A: Because I anticipate that the report might spread to more than 1 page. I don’t want every page to have the signature boxes.
Q: Don’t you know that you can show/hide the Page Footer Section (or any section) based on certain condition?
A: *Gasp* Really? Teach me how please!
The Correction
First, let’s move all the signature boxes from Report Footer Section to Page Footer Section.
Next, we need to make the page footer only to appear on the last page. We do this through ConditionalFormatting
Add a new rule “If PageNumber is not equal to PageCount, hide the section”
Now my report is less ugly 😀
Works as expected when the report spread to two pages.
I hope it helps, cheers!