ExifTool Forum

ExifTool => Newbies => Topic started by: andy95 on January 12, 2020, 12:35:15 PM

Title: Clean field (.pdf) not with "??" question mark
Post by: andy95 on January 12, 2020, 12:35:15 PM
Hello.
I have this code:

Quoteexiftool -ext pdf -overwrite_original -xmp-pdf:Producer="" -XMP-xmp:CreatorTool="" -pdf:Creator="" -pdf:Producer="" -r test\

The fields should actually be empty but two question marks appear. What can you do that the fields are empty?

Thanks for your help.
Title: Re: Clean field (.pdf) not with "??" question mark
Post by: StarGeek on January 12, 2020, 01:15:19 PM
Quote from: andy95 on January 12, 2020, 12:35:15 PM
exiftool -ext pdf -overwrite_original -xmp-pdf:Producer="" -XMP-xmp:CreatorTool="" -pdf:Creator="" -pdf:Producer="" -r test\

The fields should actually be empty but two question marks appear. What can you do that the fields are empty?

Use regular quotes ", not fancy quotes "
(or use no  quotes at all -XMP-xmp:CreatorTool= )

The command line treats fancy quotes as if they were regular characters, not quotes.  If you are copy/pasting from a word processor or Google docs, they will "help" you by changing regular quotes to fancy quotes.  If you are on a Mac, there's a setting (https://superuser.com/questions/749042/preventing-osx-from-using-smart-curly-quotes/749083#749083) that "helps" you in this way as well.
Title: Re: Clean field (.pdf) not with "??" question mark
Post by: andy95 on January 12, 2020, 02:53:02 PM
Wonderful - That is what I was looking for!

Big thanks  StarGeek! :)

Small mistake - Great impact

Title: Re: Clean field (.pdf) not with "??" question mark
Post by: Phil Harvey on January 12, 2020, 03:12:35 PM
Note that the quotes are completely unnecessary in this command (as StarGeek mentioned).  Either with or without the quotes, these tags will be deleted since the value is empty.

- Phil