Skip to main content
NickSss
Participant
July 20, 2018
Answered

Changing DocumentID via JS

  • July 20, 2018
  • 1 reply
  • 854 views

I have 2 custom stamp files that share the same DocumentID (I built one off the other). I'm unable to use both stamps at the same time and I believe it's because they share a DocumentID.

They both show up in the stamp menu, but when I select Stamp 2 the one that shows is Stamp 1. IT also shows Stamp 1's thumbnail where the second should be. If I remove Stamp 1 I can use the second stamp just fine.

Since I can't edit the DocID thru notepad (corrupts the pdf), how would I be able to do this via Javascript?

This topic has been closed for replies.
Correct answer Thom Parker

What makes a stamp a stamp is that it is marked as a page template. The stamp name is the first part of the page template name. This is what you need to change. There are different ways to do this. Acrobat automatically creates a new stamp name when you create a stamp using the built-in stamp tools.  If you just copy a file the stamp name remains the same.

So the easiest way to get your new stamp is to:

1. Move the stamp file out of the Acrobat Stamp folder.

2. Open acrobat and go to the Stamp Tools

3. Select "Create" under the "Custom Stamp" menu

4. Load your file as the image for the stamp,

This will get you a new stamp name.

You can also do this by manually editing the file and changing the Template name.

Here's are some articles that discuss the details of manually manipulating stamps.

https://acrobatusers.com/tutorials/dynamic_stamp_secrets

PDF Stamp Annotations

1 reply

Thom Parker
Community Expert
Community Expert
July 20, 2018

The Document ID comes in two parts. Each time you save a PDF, one of the parts changes, so you can't have the same DocIDs.

More likely it's because the stamp names are the same. This is the same as the template name for the stamp page in the PDF. How exactly did you build the one from the other?  Did you edit the page template name for the stamp?

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
NickSss
NickSssAuthor
Participant
July 20, 2018

They have different "Titles" under document properties if that's what you mean by name.

I made changes to Stamp 1 and 'saved as' to a different PDF with a different title. Is there something else I need to change?

Thom Parker
Community Expert
Thom ParkerCommunity ExpertCorrect answer
Community Expert
July 20, 2018

What makes a stamp a stamp is that it is marked as a page template. The stamp name is the first part of the page template name. This is what you need to change. There are different ways to do this. Acrobat automatically creates a new stamp name when you create a stamp using the built-in stamp tools.  If you just copy a file the stamp name remains the same.

So the easiest way to get your new stamp is to:

1. Move the stamp file out of the Acrobat Stamp folder.

2. Open acrobat and go to the Stamp Tools

3. Select "Create" under the "Custom Stamp" menu

4. Load your file as the image for the stamp,

This will get you a new stamp name.

You can also do this by manually editing the file and changing the Template name.

Here's are some articles that discuss the details of manually manipulating stamps.

https://acrobatusers.com/tutorials/dynamic_stamp_secrets

PDF Stamp Annotations

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often