Re: [dabo-users] Printing conditional string on report page footer

Author: Paul McNett

Posted: 2009-08-10 at 14:21:16

lalong1@charter.net wrote:

> Close...but I think it's being evaluated against the first record on the

> page vs the last.

Page headers and footers print before groups and detail. So you are

right, putting this expr in the page footer wouldn't work. And there's

nothing equivalent to the group's ReprintHeaderOnNewPage for printing

the footer on the old page.

So... an oversight. I think it's logical to change the band printing so

that the page footer prints after the group/detail for the page, however

the detail band relies on knowing the used height of the page footer, so

the page footer will have to have a fixed height.

Or, I could make a group.PrintFooterOnOldPage, which might be

technically better but harder to implement.

If you just need to get this done now, you could put this in the

PageForeground band, because here's the order of band printing on a page:

PageBackground

PageHeader

PageFooter

any continued detail (paragraph) from last page

any group footers not printed yet

any group header(s)

any detail records

any group footers

PageForeground

The trouble with PageForeground is that you need to give it absolute x,y

positions (you need to account for margins yourself). So, if you wanted

"continued on next page" to appear at the bottom of the page just inside

the margins:

<x>self.Report["Page"]["MarginLeft"]</x>

<y>self.Report["Page"]["MarginBottom"]</y>

...and it would overprint anything else that happened to be there.

Paul

©2009 Paul McNett