Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

Mailing labels: setting the first label at run-time.

edited January 2007 in General
Hello,

I am using RB 10.04 Enterprise on Delphi 7. For this report, I need to
print a page of mailing labels in 3 columns, 10 labels per column. At
run-time, the user has the option of choosing which label to begin printing
in for the first page. Page 2 and on will begin in position 1. Position 1
is column 1, row 1. Position 2 is column 1, row 2. And so on. What is the
best way to make this happen?

The first thing I tried was setting the detailband's printposition to (band
height) * (RequestedPosition - 1). That works for positions 1-11. If I set
it to 12, I get an error message as follows: "Cannot generate report:
PrintPosition exceeds available page space." I understand this means I have
set the starting row outside the printable area. How can I set the column
along with the row? The formula would be:

[Column]:= (RequestedPosition-1) div 10 + 1;
PrintPosition:= band height * ((RequestedPosition-1) mod 10);

What is the property represented by [Column]? Or am I looking at this the
wrong way? And will I need to do anything special for page 2 and onwards?

Thank you. Great product!

Comments

This discussion has been closed.