Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report with multiple headers, footers and back pages

Status
Not open for further replies.

dthorpe11

Programmer
Oct 24, 2007
4
US
The report I am working on needs to have one of six different logos print based on the value in field1. I solved this with six different group headers that conditionally print based on the value in field1.

The detail information in the report will print with summary information printing at the bottom of every detail page. The summary information is being printed in a generic group footer that is different from the groups that are used to print the logos. Because of the layout of the report, no more than ten detail lines can print on a page.

It also will need one of six different back pages to print. The logic for these is the same as the logic to determine which logo to print in the header. This was done with six different group footers

All of this works ok until there are a large number of detail lines. When this happens, the generic group footer that prints the summary information goes to the next page. This of course, throws everything off.

Does anyone have any ideas on how this can be accomplished? I basically need to be able to limit the number of detail lines printed on any page.

Thanks in advance for any help!

 
Can you please identify your groups by the field they are grouped on and also identify which one has the logos and back pages? What would you want to happen if there are, e.g., 23 records? What would you expect to see?

-LB
 
First off, thanks for responding. I hope all of this makes sense.

Report Layout:

1. GH 1, field: ID
(Always suppressed, just used to get data in correct
order when printing)

2. One of these will print and the rest will be suppressed
GH 2 field: Company - when value = 1 - Logo A
GH 3 field: Company - when value = 2 - Logo B
GH 4 field: Company - when value = 3 - Logo C
GH 5 field: Company - when value = 4 - Logo D
GH 6 field: Company - when value = 5 - Logo E
GH 7 field: Company - when value = 6 - Logo F

3. GH 8 field: ID
Contains generic header info that will print on all
pages.

4. Detail line 1: Employee Detail lines
Contains employee detail lines. One or more records for
each company. There is no limit.

5. Detail line 2
Contains generic summary info that will always print at
the bottom of each page. Must be only once on each
page.

6. Group footers
GF 2 field: Company - when value=1 - Back page A
GF 3 field: Company - when value=2 - Back page B
GF 4 field: Company - when value=3 - Back page C
GF 5 field: Company - when value=4 - Back page D
GF 6 field: Company - when value=5 - Back page E
GF 7 field: Company - when value=6 - Back page F

This above scenario works correct when there are ten or less employee detail records for a company. When there are more than ten records, detail line 2 (5) will go to the next page.

Examples:

This works correctly:
Logo A
Generic Header
Detail 1
Detail 2
Detail 3
Generic Summary
Back page A

This does not work:
Logo A
Generic Header
Detail 1
Detail 2
Detail 3
Detail 4
Detail 5
Detail 6
Detail 7
Detail 8
Detail 9
Detail 10
<<page break>>
Detail 11
Generic Summary
Back page A

 
Sorry, I don't believe that those are the report sections you can be using. Do you have more than one group? What is the second group? I think you are referencing different sections a, b, c, etc. of the same group for the logos and the back pages. There are no details 1 and 2, only detail_a and detail_b, but you wouldn't see detail b only at the bottom of the page unless you conditionally suppressed earlier records. Not sure how you did this. Please reference actual report sections. You also did not explain how you would expect the display to look if there were 23 records. Or you could show what you would want with 13.

-LB
 
You are correct, sorry I didn't explain it very well. GH2 - GH7 are separate groups. They all have suppression logic behind them so that only one will ever print. They are all based on the same field, they just have different suppression logic behind them. The group footers for each group contain the back page that will be printed and have the same suppression logic as the headers.

I do have a line counter formula imbedded on detail A. Detail line B has suppression logic not to print unless the line counter is > 10.

If there were 23 records, I would want two pages with 10 to print and then one page with 3.
 
Do you ever have the report run to show company a and b and c all in one report? Is so, would a group by company work to show them. then all of the logos could be put in the single group header and footer on top on one another and conditionally suppressed unless it matched the goupname you needed.
Code:
if groupname <> logo

IF you do not have more than one company at at time in the report, then why not use a parameter field to ask the user what "company" they are running the report for? Then have the logos display based on the parameter. Good luck.
 
When the report is run, it will usually include more than one company. It was originally designed with all of the logos on top of each other. This was difficult to manage when the 4th or 5th logo down needed to me changed. The multiple groups are just to make it easier to maintain. The logos print correctly.

The only issue I'm having is when there are more than 10 detail records printing, it kicks the summary to the next page and then everything is thrown off from there forward.
 
Please show what you expect to see using the report sections.

Are you expecting the group footers to appear after 10 records? What kind of summaries would you want to see after 10 records, since they wouldn't be the entire group?

-LB

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top