Author Topic: Copy "CreateDate" (Xmp) to "ModifyDate" (Exif) in jpeg files in batch process  (Read 3576 times)

The Black

  • Newbie
  • *
  • Posts: 5

Hello,

I want to copy the values in the "CreateDate" tags in the Xmp metadata
to the values in the "ModifyDate" tags in the Exif metadata.

I want to do this for several (about 500) jpeg files at one time in a
batch process.

Please tell me if this is possible and if so, please give me detailed
instructions as I am not experienced in using the ExifToolGUI software.

Thanks.

StarGeek

  • Global Moderator
  • ExifTool Freak
  • *****
  • Posts: 2909
Not to many people here use the gui as it is no longer supported, though it still seems to work.

You might try this in the "exiftool direct" section.  Try it on a test file first, though.
"-exif:Modifydate<Createdate"
Troubleshooting hints:
* When posting, include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).
* Double all percent signs (%) in a Windows batch file.
* If your GPS coords are negative, make sure and set the GpsLatitudeRef and GpsLongitudeRef tags correctly.

The Black

  • Newbie
  • *
  • Posts: 5
Hi StarGeek,

Thanks so much for the reply.

Your command worked perfectly and the date in the "ModifyDate" tag in the
Exif metadata was changed to the "CreateDate" tag in the Xmp metadata
of the jpeg image (was tested on only 1 file as per your suggestion).
The changed data was displayed in the ExifToolGUI window.

But this changed value was not reflected/displayed by Windows Explorer in
its "Date Modified:" property. So it seems that the property changed by
ExifToolGUI has no bearing on what Windows displays and it must read its
date information from somewhere else in the file's propeties.

I even tried the command "-xmp:Modifydate<Createdate" instead of
"-exif:Modifydate<Createdate" so that the value in the xmp properties was
changed, and although ExifToolGUI showed the change, Windows Explorer
did not.

Thanks again for your prompt and helpful reply. Any furthur help to change the
date such that Windows Explorer displayed it would be much appreciated.

Cheers ...

StarGeek

  • Global Moderator
  • ExifTool Freak
  • *****
  • Posts: 2909
See this post for the list if tags that windows reads the "Date Taken" property from.

tl;dr, copy to EXIF:DateTimeOriginal instead of ModifyDate.
Troubleshooting hints:
* When posting, include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).
* Double all percent signs (%) in a Windows batch file.
* If your GPS coords are negative, make sure and set the GpsLatitudeRef and GpsLongitudeRef tags correctly.

The Black

  • Newbie
  • *
  • Posts: 5
Hi again,

I've read the post with the list of tags that Windows reads the "Date
Taken" property from and I used the command EXIF:DateTimeOriginal and
this created a new Exif tag "DateTimeOriginal" as displayed in the
ExifToolGUI metadata.

But I wanted to update/change the "Date Modified" value and not the
"Date Taken" value as mentioned in your last post. The "Date Taken"
values for the jpeg files are already correct and so the goal is to
copy this correct date for all files to their respective "Date Modified"
values so that Windows Explorer displays the same correct values for
both "Date Taken" and "Date Modified".

However, in the list linked in your last post, there is no "Windows
property, File type" tag for "Date Modified" and only the "Date Taken"
value is listed.
Does this mean that ExifTool cannot read or write the tag for Windows
"Date Modified" ?

Please help.

Thanks for your reply.

StarGeek

  • Global Moderator
  • ExifTool Freak
  • *****
  • Posts: 2909
My apologies, I misread your post.

The tag you want is FileModifyDate
Troubleshooting hints:
* When posting, include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).
* Double all percent signs (%) in a Windows batch file.
* If your GPS coords are negative, make sure and set the GpsLatitudeRef and GpsLongitudeRef tags correctly.

The Black

  • Newbie
  • *
  • Posts: 5
Hi,

Thank you for your reply.

When using the tag "FileModifyDate" the following error message
was displayed :
(<filename> has been substituted by me in place of the actual filename)

======== <filename>.jpg
Nothing changed in <filename>.jpg
    0 image files updated
    1 image files unchanged
Warning: Tag 'exif:FileModifyDate' is not defined - <filename>.jpg
Warning: No writable tags set from <filename>.jpg
<-END-

Any ideas?

Thanks.

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 15346
    • ExifTool Home Page
FileModifyDate is a File System tag, not an EXIF tag.  So just drop the "exif:" and you should be good.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

The Black

  • Newbie
  • *
  • Posts: 5
Hi Phil,

Thanks for your reply.
Please help me out by giving the full command line you want me to use.
What do I use in place of "exif:" as when I used just
"FileModifyDate<CreateDate" an error message was displayed as below :
    1 image files read
    1 files could not be read
File not found: FileModifyDate<CreateDate
<-END-

Thanks again and please help.

StarGeek

  • Global Moderator
  • ExifTool Freak
  • *****
  • Posts: 2909
You need a dash in front of FileModifyDate
"-FileModifyDate<CreateDate"
Troubleshooting hints:
* When posting, include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).
* Double all percent signs (%) in a Windows batch file.
* If your GPS coords are negative, make sure and set the GpsLatitudeRef and GpsLongitudeRef tags correctly.