0
How can I automate adding metadata to a PDF document?
Participant
,
/t5/acrobat-discussions/how-can-i-automate-adding-metadata-to-a-pdf-document/td-p/12587599
Dec 11, 2021
Dec 11, 2021
Copy link to clipboard
Copied
Hi Good day,
There are thousands of pdf files, how can I automate adding metadata to these pdf documents?
File name > adding it to the title and subject sections
Thanks....
TOPICS
JavaScript
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
Community Expert
,
/t5/acrobat-discussions/how-can-i-automate-adding-metadata-to-a-pdf-document/m-p/12588119#M341822
Dec 12, 2021
Dec 12, 2021
Copy link to clipboard
Copied
You can do it using the Action Wizard in Acrobat Pro.
Create a new Action and add to it an Execute JavaScript command with the following code:
this.info.Title = this.documentFileName.replace(/\.pdf$/i, "");
this.info.Subject = this.documentFileName.replace(/\.pdf$/i, "");
Make sure to un-tick the Prompt User box, and then add a Save command after this command, and run it on your files.
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
idjev
AUTHOR
Participant
,
LATEST
/t5/acrobat-discussions/how-can-i-automate-adding-metadata-to-a-pdf-document/m-p/12588231#M341828
Dec 12, 2021
Dec 12, 2021
Copy link to clipboard
Copied
you are great,
thanks a lot
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

