Skip to main content
Known Participant
December 19, 2017
Répondu

Dated watermark on .pdf

Hi. I am using InDesign CC 2018 and Acrobat Pro DC.

I would like to have a watermark on my .pdf that shows the current date. I'd want it to update to the current date each time it is opened..(like how a Word document does so with letterheads, etc.) The date would be in the background on a price list document.

First of all, should I do this in Acrobat or InDesign? Not sure if possible. I see there are separate programs or plugins, but thought Acrobat would have something available.

Thank you.

Ce sujet a été fermé aux réponses.
Meilleure réponse par try67

You should do it in Acrobat. Create a text field. Let's say it's called "Today".

Then go to Tools - JavaScript - Document JavaScripts and create a new item. Let's call it "scripts".

Enter this code into the editor window that opens:

this.getField("Today").value = util.printd("dd/mm/yyyy", new Date());

Save the file and you're done.

1 commentaire

try67
Community Expert
try67Community ExpertRéponse
Community Expert
December 19, 2017

You should do it in Acrobat. Create a text field. Let's say it's called "Today".

Then go to Tools - JavaScript - Document JavaScripts and create a new item. Let's call it "scripts".

Enter this code into the editor window that opens:

this.getField("Today").value = util.printd("dd/mm/yyyy", new Date());

Save the file and you're done.

Known Participant
December 20, 2017

Can the text field be from the Comments in Tools or do I have to treat this pdf like a form?

try67
Community Expert
Community Expert
December 20, 2017

I've closed it and reopened and closed Acrobat and reopened the file, still blank.

I even tried going to the text fields properties and clicking Format and trying to add the JavaScript there, but it won't seem to let me. Keeps reverting to None even if I close the program and try again or even try on another computer.


Press Ctrl+J and check for error messages. If there are none then you'll need to share the file with us (via Dropbox, Google Drive, etc.) for additional help with this.