Imagine having to stamp your name and the current date onto about 60 PDFs, every single day.
Sounds tedious, right?
That was the problem a user brought me at work.
What did not quite work
My first thought was to use an image or a signature in Adobe Acrobat Pro, but neither seemed to solve the problem of having a date that updates automatically. A static image of yesterday’s date is fine once. It is a nuisance when the calendar moves on and the same files need today’s date again.
A dynamic custom stamp
Then I found something new to me. Adobe Acrobat’s Stamp feature supports dynamic fields using JavaScript.
I had never tried this before. At first I thought it would have the same limitation, but it turned out I could make a custom stamp that inserts a fixed name plus the current date.
The JavaScript for the date field turned out to be surprisingly simple:
event.value = util.printd("dd/mm/yyyy", new Date)
After some setup and testing on the user’s own computer, I got it working. Stamp files can also be created on another machine and shared across, but in this case building it directly where it would be used kept things simple. Now, instead of manually entering the details for every PDF, the user can simply apply the stamp.
The accompanying walkthrough shows a custom stamp with a fixed name plus that dynamic date field (illustration only, not a real workplace identity).
The user no longer has to enter the same details by hand, and I learned something new along the way.
Adobe’s official walkthrough is here: Create custom dynamic stamps in Acrobat (there is also an older KB article, Create a custom dynamic stamp using Acrobat).
Takeaway
Sometimes the answer is a feature in an app you already have, rather than another tool or a complicated bit of automation.
Originally shared on LinkedIn.