Print Page | Close Window

Sequential numbering to each page printed

Printed From: Foxit's Planet PDF Forum
Category: Lets Talk PDF
Forum Name: JavaScript
Forum Description: Discussions relating to the use of JavaScript within PDF.
URL: http://forums.planetpdf.com/forum_posts.asp?TID=3958
Printed Date: 23 Mar 2019 at 11:00am
Software Version: Web Wiz Forums 11.10 - http://www.webwizforums.com


Topic: Sequential numbering to each page printed
Posted By: CannonFodder
Subject: Sequential numbering to each page printed
Date Posted: 01 Mar 2018 at 1:17am
Hi All,

I have a PDF spreadsheet that contains a text box where you enter a building number, what I need is a code that when the page is printed more than once, it adds 1 to the total on the next page printed & so on. Example of a building number would be 312180001, if there are 10 components to this building I am currently printing 1 page, then manually changing the number to 312180002 & printing a second page & so on. Is there a code that if I ask for 10 copies it will auto update each page (+1 to number in text box) before it prints? Thank you for any advise guys - Marco


-------------
Marco



Replies:
Posted By: kevindebenu
Date Posted: 20 Mar 2018 at 9:48am
Hello Marco,

There is a willPrint event, but this is only for the entire document.

The willPrint event is only called once, even if the number of copies is more than 1.

On a technical level, the number of copies is just sent to the OS printing which replicates the pages (possibly the printer itself handles the duplication). So it's not possible to have different content for each copy of the page.

And lastly, the willPrint event doesn't report the number of copies.

It doesn't seem possible to achieve what you would like to do using Acrobat.

The only solution I can think of would be to develop a custom application that handles the printing, adjusting the number on the page before printing each page.

Regards,
Kevin



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.10 - http://www.webwizforums.com
Copyright ©2001-2017 Web Wiz Ltd. - https://www.webwiz.net