Skip to main content
Participant
Jul 14, 2016 10:08 PM UTC
Question

Used Javascript in Document Actions to create dynamic watermark to display print date, however it doesn't work in Acrobat Reader, even though Javascript is enabled. Is it because watermarks cannot be created in Reader?

Below is the script that I used under "Document Will Print".  when I tested using Adobe Acrobat Pro DC it worked great. When I tested using Adobe Reader XI, the date did not show up, even though JavaScript was enabled.  Any suggestions?

this.addWatermarkFromText({

cText: util.printd('mmm d, yyyy h:MM tt', new Date()),

nHorizAlign: app.constants.align.center,

nVertAlign: app.constants.align.bottom

});

This topic is closed to new replies. Start a new post to keep the conversation going.

9 replies

try67
Community Expert
Community Expert
Jul 15, 2016 6:35 AM UTC

You should use a text field instead.

On Jul 15, 2016 12:10 AM, "lorraineh58962332" <forums_noreply@adobe.com>

Translate
Participant
Jul 15, 2016 2:02 PM UTC

I tried putting a text field into a stamp, however couldn't get it to update the date. Would you happen to know what javascript I should use inside a text field; maybe I had the wrong script.

Translate
try67
Community Expert
Community Expert
Jul 15, 2016 2:23 PM UTC

The script would be something like this:

this.getField("PrintDate").value = util.printd('mmm d, yyyy h:MM tt', new Date());

Translate
Inspiring
Jul 15, 2016 4:47 AM UTC

That's right, Reader doesn't support that JavaScript method.

Translate
Participant
Jul 15, 2016 2:03 PM UTC

Do you have any suggestions as to how to get the "date printed" to show up on a pdf in Reader?

Translate