X of Y

Nancy Palmquist nlp at vss3.com
Sat Oct 15 17:57:42 PDT 2005


Chistopher,

I have seen simple and complex solutions to this.  Here is the easiest.
If you have an invoice header with detail lines and keep a count of 
number of lines on the invoice, it becomes a simple math problem.

But as other said, you must know that each invoice lines takes x number 
of lines.  Also how many lines print on a page.  Then just take number 
of lines on invoice / number of lines per page.  Round it up and you 
have the number of pages.  Adjust for subtotals on the last page which 
might take some lines away from the details.

Now as Keith suggested, a great way is to collect the entire invoice 
into arrays until you get to the bottom of the invoice.  Then feed the 
data onto the paper.  You will have all the data for the entire invoice 
at your finger tips and it will be easy to print subtotals at the top or 
X of Y pages, etc.  Just create arrays for all the columns on the 
invoice.  Put a list of variables down the left side of the invoice. 
(aa,ab,ac,ad,...  az, ba, bb, ... bz, ca, cb ... )  Map them to an array 
and just work top to bottom on each page.  A great way to make one 
process print different forms on the same paper. (Credit Memos, 
Invoices, Orders, Packing Slips) all in one pass thru the data if you want.

Nancy



-- 
Nancy Palmquist 		MOS & filePro Training Available
Virtual Software Systems	Web Based Training and Consulting	
PHONE: (412) 835-9417		   Web site:  http://www.vss3.com



More information about the Filepro-list mailing list