Copy link to clipboard
Copied
I have a 4-page form of which the 4th page is a summary of the data entered on the first 3 pages. I'm 'building' this 4th page using form fields that get their data from the other pages. While it works really well, there is one thing I'm hoping is possible:
If a field (let's say field C on page 1) is empty, it won't get shown on page 4, but there will be space 'reserved' for the data, creating a gap between fields B and D. In that case, I'd like to have all fields following field C to move up the page and 'close the gap'.
Is this possible?
Yes, it is possible. Scripts can move field locations in Acrobat/Reader. I don't know how other viewers will handle such code. They probably won't, but I know it will work in Acrobat and Reader.
The location of the field is determined by it's "rect" property. You'll need to learn about PDF page coordinates and performing simple geometry calculations.
Here is an article on page coordinates, which includes scripts for moving fields
PDF Page Coordinates (page size, field placement, etc.)
Check out t
...Copy link to clipboard
Copied
Yes, it is possible. Scripts can move field locations in Acrobat/Reader. I don't know how other viewers will handle such code. They probably won't, but I know it will work in Acrobat and Reader.
The location of the field is determined by it's "rect" property. You'll need to learn about PDF page coordinates and performing simple geometry calculations.
Here is an article on page coordinates, which includes scripts for moving fields
PDF Page Coordinates (page size, field placement, etc.)
Check out the "Swat the Fly Game" and "Bouncing Button" sample files here:
Free Sample PDF Files with scripts
Both move fields. And the scripts are open for you to see.