Question

I have a report that contains two main subreports, each taking a vertical half of the page, so they go side by side. Each has their own page header which I emulate by using a groupheader and seting the RepeatStyle property to OnPageIncludeNoDetail. However, both may have a different length, and I want the rightmost subreports to show the page header even if the report has no more data to show. In other words, if the right subreport takes less pages than the left report, I need for it to keep printing the header data on each page until the leftmost report ends. This is failing right now because once the subreport on the right is finished, it assumes the header needs not to be printed anymore.

I've tried adding a page break at the bottom of the subreport on the right, but as I don't know how many pages either of the subreports have, I don't know whether I should enable it or not until too late (or at least I didn't find a way to do so). BTW, I'm using AR3 but upgrading to AR7 is supposed to occur at some point of the future...

Was it helpful?

Solution 3

I found a way to do this although it is not flawless. But the problem may be only on AR3 and hopefully fixed on AR7. What I did was move the right subreport's header on a separate header of the master report. So now the master report has a page header, then the new group header (let's call it ghPage), and lastly the group header that originally contained both subreports. Then, I set ghPage's property UnderlayNext to true, taking care to leave the necessary blank space to let ghPage fit in. That's it, and it seems to work, but... when the left side subreport takes less than the right's page header high, this last section appears cropped to the left's height.

OTHER TIPS

Once a subreport ends and is no longer being put on each page it won't be possible to get it's page header rendered on the next page. I think your best option here is to use a parent report to include the pageheader information as only a parent report will continue to render as long as either one of the subreports render.

Note: It doesn't need to be the same parent report you're using now, but you could be another in between the current parent report and the two subreports to deal with the page headers.

I would suggest that you use groupheader/footer in the subreports instead of pageheader/footer and set the repeatstyle property of groupheader to OnPage.. Pageheader/footer in subreports are not supported because Subreports are not page aware.

The pageheader/pagefooter of the main report with render fine as scott mentioned.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top