ExifTool Forum

ExifTool => The "exiftool" Application => Topic started by: drramimagdi on May 22, 2022, 04:08:18 PM

Title: how to batch rename all pdf files in a folder to the pdf metadata title?
Post by: drramimagdi on May 22, 2022, 04:08:18 PM
i tried a code that i found elsewhere but it's not working
exiftool.exe -d %Y '-fileName${Title} - $Author [$CreateDate]'.pdf  -ext pdf
Title: Re: how to batch rename all pdf files in a folder to the pdf metadata title?
Post by: StarGeek on May 22, 2022, 04:23:57 PM
You didn't include the tag copy operation. Try
exiftool.exe -d %Y '-fileName<${Title} - $Author [$CreateDate]'.pdf  -ext pdf

Though this will fail if any one of Title, Author, or CreateDate doesn't exist.  If this command fails, it helps if you copy/paste the output and use the Code Button (https://exiftool.org/forum/index.php?topic=4888.msg69111#msg69111) on the output.