Skip to main content
Participant
October 10, 2022
해결됨

Script for Batch sign multiple pdf documents at once ?

  • October 10, 2022
  • 3 답변들
  • 20207 조회

I have 1000 similar documents that all need to be signed in the same location on the document on page 1. Is it possible to do so by scripting in Adobe without having to individually open sign and save the document?

Adobe Acrobat Pro. Same location on the same page in all files and digital signature. 

이 주제는 답변이 닫혔습니다.
최고의 답변: try67

Adobe Acrobat Pro DC

Coutinous release version 2022.002.20191 64 bit

 

OS Version 

Edition Windows 10 Business
Version 21H2
OS build 19044.1586
Experience Windows Feature Experience Pack 120.2212.4170.0


Then you can use an Action (Tools - Action Wizard) with the following code:

 

var sigField = this.addField("Signature1", "signature", 0, [10, 67, 122, 24]);
var mySignatureProfileFilePath = "/C/Users/YOUR_USER_NAME/AppData/Roaming/Adobe/Acrobat/DC/Security/TEST.pfx"; // ADJUST TO ACTUAL FILE PATH ON YOUR COMPUTER
var myPassword = "ABCD1234"; // ADJUST TO ACTUAL PASSWORD FOR THE PROFILE SELECTED ABOVE
var myEngine = security.getHandler( "Adobe.PPKLite");
if (myEngine.login(myPassword, mySignatureProfileFilePath))
	sigField.signatureSign( myEngine, { password: myPassword});
else app.alert("Error! Could not login to the Security Handler.");

 

This will add a Signature field to the bottom-left corner of the first page and then sign it using the specified signature profile. However, you might be prompted to save the file manually after doing so... If it's not, add a Save command to your Action, after the command that executes this JS code.

3 답변

Participant
May 11, 2023

Hello, i have a similar problem. I want to sign a batch of 12 contrats, each one with 4 pages, and signature (digital certificate) should be on the last page. I want a find the way of only having to enter the signature PIN 1 time (i´m using a card reader). My Adobe version is 

Architecture: arm64

Processor: Apple M1

Build: 23.1.20177.0

AGM: 7.0.4

CoolType: 8.2.1

JP2K: 4.0.0.52671

Participant
May 15, 2023

No help?

sergiolucianojr
Participant
October 19, 2022

@try67, I tried using this code, but the signature field was not filled. Maybe I am doing something wrong?

 

The folder of my certificate is write like this:

"/Z/OneDrive/1. Colibri/0. Contabilidade e Finanças/99. Certificado Digital/2022/Certificate.pfx"

 

Should I, instead of that, use _ istead of spaces, like this?

 

"/Z/OneDrive/1._Colibri/0._Contabilidade_e_Finanças/99._Certificado Digital/2022/Certificate.pfx";

 

 

I would like to do something similar you indicated, but with a small change:

 

- I want an invisible signature, not a visible one

- I would like block the document after sign

 

Could you help me with that?

sergiolucianojr
Participant
October 19, 2022

Just to let you know...

I tried also using the _ instead of space, but I still can't load automatically the signature to the filed that was created.

try67
Community Expert
Community Expert
October 10, 2022

Do the files already contain a digital signature field? If so, does it have the same name in all files?

 

Participant
October 11, 2022

no digital signature field.

try67
Community Expert
Community Expert
October 11, 2022

So the Action should add a digital signature field and then sign it? Should it always appear on the same page and in the same location?