[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: VariableReport Headings



On Thu, 7 Sep 2000, Huber, Robert wrote:

> I have a situation where the number of lines needed for the heading of a
> given report changes during the generation of the report. I realize that the
> number of lines in the heading could be set to the max needed but that would
> leave too much white space after the heading when the heading does not take
> up the entire max number of lines. One could have multiple reports with
> different headings but then the problem is how combine the several reports
> into one. I would rather not have to generate the report headings
> "manually". Any ideas?

Well, it's easy in version 6.0, just use the...

ALTER-REPORT +6.0
          [HEADING= t_heading_name]
          [HEADING-SIZE= n_new_size]
          [FOOTING= t_footing_name]
          [FOOTING-SIZE= n_new_size]

command.  (Where the items begining with a "t_" can be any text Variable,
Literal, or Column reference, and "n_" can be any numeric Variable,
Literal, or Column reference).

With prior versions, you might try setting the heading to a minimum
setting and printing into the body of the report from the heading for the
longer ones. This can be very tricky since you will always have to check
if a position() or next-listing caused a new-page so that you can move
down past the heading, and you won't be able to use a print position of
(+1, n) anywhere where that might trigger a new-page. If every page is
self contained within a page boundry, then it's relatively easy.

Another option (if you're main concern is white space, and not that you
need every possible line for the data) is to set the heading to the
maximum, and print the smaller lined headings spread out, or starting
farther down the heading (so the white space looks like a larger margin).
Not as neat, but less work.

-----------------------------------------------------------------------
Donald Mellen  | Ray Ontko & Co. - Richmond, IN - http://www.ontko.com/
donm@ontko.com |  "In the beginning, there was nothing, which exploded"