Hi,
I’m working with Avery label templates in Clarion 8 reports. For example:
Avery 5160 → 3 across × 10 down = 30 labels per page (2.625" × 1.0")
Avery 45008 → 3 across × 7 down = 21 labels per page (2.815" × 1.5")
I set my Detail band to the correct label size (PROP:Width, PROP:Height) and labels are printing correctly.
But when I have more than 30 records for Avery 5160, Clarion sometimes tries to print the 31st label on the same page, instead of starting a new page.
I tried tricks like making ?Detail{PROP:Height} = LabelHeight + 2, but that misaligns the labels on the physical Avery sheet.
Question:
What is the correct way in Clarion to force a page break after N labels (e.g. after 30 for 5160, after 21 for 45008), regardless of whether Clarion thinks there’s still space left?
Do I need to:
Use REPORT{PROP:PageBreak} = TRUE?
Or manage row/column counters and issue a break manually?
Or is there a Clarion Report Designer setting that handles this automatically?
Any working example of forcing exact page breaks by row/column count would be really helpful.
And/or probably the REPORT AT( detail print area ). Overflow occurs when there is no more room on the page Detail Print Area defined by the AT(,w,h) of the Report.
I would think you would have PAPER(Paper:Letter) since the sheets are Letter size.
For the 5160 that is 3 across × 10 down = 30 labels per page (2.625" × 1.0")
The Report would have AT Width as 3 * 2.625" = 7875
The Report would have AT Height as 10 * 1.0" = 10000
The Report AT(X,Y) would be adjusted to get the labels in the right spot. That is often specific to the User’s Printer and would be adjusted at runtime with Report${PROP:XPos} and Report${PROP:YPos}
E.g. lets say you print at 1/4" and 1/2" margins so for 5160 try Report AT(250,500,7875,10000)
When your DETAIL’s sized AT(,,2625,1000) run out of room in the 7875 x 10000 Detail Print Area the page should overflow and eject for a new page.
I have done a lot of Manual Report Paging where each Detail Height is counted. I have found the Print Engine sometimes increases the Band Height a little which threw off my counting.
The fix is the below code to prevent the engine from increasing Height. For you I would also do Width.
An alternative approach would be to put the ABSOLUTE attribute on the Label Detail.
You must set the Prop X,Y for the Detail before you Print(). That would would be an easy calculation of X=(Column-1)*2.625 and Y=(Row-1)*1.0. When Row is 11 do an EndPage() and reset counters to 1.