General information
Category:
Reports & Report designer
---
header to print conditionally, but the page footer insists on printing no matter what. This means they get a page with nothing but the page footer in cases where they're printing a single job#. The condition I'm using in the Print When is (not EOF() or Job = 0)
Anyone have a suggestion how I can get the report footers to stop printing on this last page when I'm not printing a summary?
---
You're probably not at EOF() at that point when scoping, Barbara. So... off the top of my head:
This is a situation where a report variable will probably be useful. Initialize to .F. and set its value to its own name, so it doesn't change during the report.
Now use an expression such as the following for your OnEntry for Summary:
execscript("rptInSummaryBand= .T.")
... now your Print When is something like:
(NOT rptInSummaryBand) OR addtl_conditions_you_have_for_condtl_printing.
One more thing:
If you are going to preview this report, you'll want to set another execscript to toggle it back to .F. in OnEntry for other bands, in case they page backwards after hitting the last page. If there's a _PAGETOTAL, forcing a prepass, you'll probably have to do the same thing. Because those events are going to be evaluated multiple times in VFP 8 preview, as they page back and forth, you have to make sure the value of the variable is *always* right.
You could probably do the same thing with initializing and resetting the variable on group, but using the band OnEntry events will be a little more predictable.
Give that a try?
>L<
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only