Copy link to clipboard
Copied
Hi, need help!
I created a form with signature filed and selected "read-only" all fields (refer to picture) once signed.
Submiited the pdf via outlook email. When the form received the date, time and other fields are editable.
I am using Acrobat Pro ver. 2024.005 203.20 (64bits), any help appreciated. Regards
Copy link to clipboard
Copied
Read-only executes after the form is signed.
Copy link to clipboard
Copied
Thanks for the response.
Where do I add the JS: this.getField("FieldName").readonly = true;
Actions or Signed Tab
Copy link to clipboard
Copied
Are you trying to make the fields read-only with your submit button as the trigger, or signing the form with the digitial signature field as the trigger?
Copy link to clipboard
Copied
I am doing away with singnature field, just submit button as the trigger to lock all field no one can edit.
Copy link to clipboard
Copied
You can flatten the fields instead of read-only which will turn them into static text with this simple line of code prior to your submit code:
this.flattenPages();
Be aware the form fields, including the submit button, will no longer exist as fields, and the user who clicks the submit button must have Acrobat. If you want to go the read-only route you will need to loop through all of the fields like this:
for(var i = 0; i < this.numFields; i++)
{
var fieldName = this.getNthFieldName(i);
var oFld=this.getField(fieldName);
if(oFld==null){continue}
oFld.readonly=true;
}
Copy link to clipboard
Copied
Thank you.