Insert a text box in PDF and fill data from Excel using VBA

Ameena K

New Member
Joined
Apr 8, 2021
Messages
3
Office Version
  1. 2019
Platform
  1. Windows
Hey guys,

I want to use VBA to insert a single text box at the end of each page in a pdf file using the data from Excel worksheet. Please help.
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
This can be done with VBA and the Acrobat API, which is only available if Acrobat Pro (not the free Adobe Reader) is installed.
 
Upvote 0
This can be done with VBA and the Acrobat API, which is only available if Acrobat Pro (not the free Adobe Reader) is installed.
Thank you for your reply. Does the version matter? Also, do I have to use Acrobat Javascript Reference?
 
Upvote 0
The version of Acrobat Pro shouldn't matter and an Acrobat reference isn't needed, as the code can late bind to the Acrobat library objects.
 
Upvote 0
The version of Acrobat Pro shouldn't matter and an Acrobat reference isn't needed, as the code can late bind to the Acrobat library objects.
Could you please demonstrate a simple example to insert a text box at a particular part of the page? I am not able to do it without JavaScript reference.
 
Upvote 0
Which JavaScript reference are you talking about? I've never used any JavaScript reference for manipulating PDFs. The only one I've used, and only if early binding, is Adobe Acrobat Type Library.

This code adds a text box on every page:
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,827
Messages
6,121,818
Members
449,049
Latest member
cybersurfer5000

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top