ExifTool Forum

ExifTool => The "exiftool" Application => Topic started by: ajacobs on February 16, 2021, 04:25:43 PM

Title: Add datetime to scanned pictures + XPTitle tag
Post by: ajacobs on February 16, 2021, 04:25:43 PM
I have a lot of photos scanned from negative and positive films from years ago. I want to set dates and times on these pictures. The time with an increment of 5 seconds. A second thing I need to do is adding XPTitle from filename for my QNAP Qphoto application.
I have looked around and have found a solution. The only thing I asked is, if it is possible to do it in one run.
I have done it this way and it works:
REM %1 yyyy:mm:dd
REM %2 Directory
•   exiftool %2 "-XPTitle<${filename;s/\..*?$//}"
•   exiftool -P -overwrite_original -fileorder filename "-AllDates=%1 00:00:00<0:0:${filesequence;$_*=5}" %2 
•   exiftool -fileorder filename -overwrite_original "-AllDates+<0:0:${filesequence;$_*=5}" %2
example cmd file changedate.cmd:
changedate 1973:06:01 "Y:\Foto\197306 Parijs"
Title: Re: Add datetime to scanned pictures + XPTitle tag
Post by: StarGeek on February 16, 2021, 04:39:26 PM
You can merge the "-XPTitle<${filename;s/\..*?$//}" part with either of the other commands, just append it the end. But AllDates must be set before the increment.  It's technically possible to merge that as well using the -execute option (https://exiftool.org/exiftool_pod.html#execute-NUM), but it really isn't worth the effort.  It won't save any time (exiftool has to make two passes no matter what) and if you're new to exiftool, as it would make troubleshooting an error more difficult.

Also, you might look to see if you can use another tag other than XPTitle (maybe Title or ObjectName, as those would be the equivalent tags) just to future proof the files.  XPTitle is used pretty much by only Windows OS and very few other programs will use it.  I'm actually a bit surprised that a Linux based system would use it.
Title: Re: Add datetime to scanned pictures + XPTitle tag
Post by: ajacobs on February 20, 2021, 09:17:49 AM
I have followed your recommendations, thanks.
Also added some suggestions for exiftoolgui:
When I start exiftoolgui then it disappears after a few seconds.
But after some testing, is my experience that you could prevent this behavior:
•   By Deleting ExifToolGUIv5.ini
•   By not using full screen and set [ExifToolGUI] StartMax=0
•   Make a exifGui.cmd file with: call ExifToolGUI
I prefer the later because it seems the most stable, but I don't know why. 

Title: Re: Add datetime to scanned pictures + XPTitle tag
Post by: StarGeek on February 20, 2021, 11:07:06 AM
The ExiftoolGui has not been supported in nearly a decade (https://exiftool.org/forum/index.php?topic=4553.msg21674#msg21674).