Is there a way to export a jpg EXIF info?

Ask for help and post your question on how to use XnView MP.

Moderators: XnTriq, helmut, xnview

Post Reply
bubbalicious
Posts: 3
Joined: Sun Mar 21, 2021 1:36 pm

Is there a way to export a jpg EXIF info?

Post by bubbalicious »

I did a search and didn't find an answer, so I apologize in advance if this has been answered and I missed it!

I want to do a jpg EXIF info export for a batch of jpg files in a folder (the info can be seen in the "info" tab where the "preview" tab is). I'm doing a project and it would be very helpful to bring up a plain text file to see the info. Am using XNView MP, latest version.

If there is a way to do this, could you give specific instructions? Thank you in advance! :)

Nikki
User avatar
michel038
XnThusiast
Posts: 1291
Joined: Tue Sep 27, 2016 8:18 am
Location: France
Contact:

Re: Is there a way to export a jpg EXIF info?

Post by michel038 »

Wich exif metadata do you need ? hundreds can be found ....


Some ideas :
1) Go to Settings, metadata, ensure that "Export categories" and "create sidecar" are not ticked.
- Select a photo, "View, Update files from catalog"
- A Xmp file is created , containing (perhaps) all the exif data, in xml format
But with this method, you obtain a xml file for each photo

2) Create , File listing...
- Use the green + to add a field.
- Use the right triangle arrow, and choose the exif data you want to be present in the result
- repeat these steps
You will get a text file containing columns for each field you added
But with this method, you can only get some known exif metadata in the file

3) Tools, Open with, Configure programs, Add .... browse the installation folder of XnViewMP, go to AddOn and select exiftool.exe
- Double click in first column and name it Exif2txt.
- Double click in 2nd column and add this parameters -k "-exif:all" -w txt
-Select some photos, right-click, Open with, Exif2txt ... close the exiftool window :
Text files with the same name as the photos with txt extension are created.
But with this method, you get a txt file for each photo

4) The last but not the least
With windows.
- Create a folder like C:\test
- Copy exiftool.exe in this folder
- Create a new text file in this folder, containing

Code: Select all

C:\test\exiftool.exe -csv -m "-exif:all" %* > c:\test\result.csv
pause
-Rename this text file ExifToCsv.bat
- Go to Settings, Interface, Toolbar. Select "Command" and move it to the right side.
Select this command and click "set command" button. Browse C:\test folder and select : ExifToCsv.bat
You can choose also a label and an icon

then
Select photos, click the new button ... tadaaam a (very wide) result.csv file will contain all exif data in columns.
CSV format can be opened also by Excel or Calc
The "pause" that I added in the bat file allows you to read exiftool's report before you close the window.

edit
- ExifToCsv is working
- You can also drag and drop files from xnview, or from w explorer, on ExifToCsv.bat
User avatar
Rick
Posts: 233
Joined: Sat Oct 08, 2005 4:10 pm
Contact:

Re: Is there a way to export a jpg EXIF info?

Post by Rick »

@michel038
What a wonderful, informative reply!
Thanks
--
Rick
bubbalicious
Posts: 3
Joined: Sun Mar 21, 2021 1:36 pm

Re: Is there a way to export a jpg EXIF info?

Post by bubbalicious »

Dude, YOU ROCK!!! I really appreciate your detailed explanation and this is the info I was looking for, and how to accomplish my "mission." As for which exif metadata I'm wanting from the images, it's mostly going to be the date taken, camera model and file name, for reference. I'm making a book of images (but first editing them in Affinity Photo and then exporting the final to png format for the book), and want to be able to know a date for the picture for a brief image date and description below the picture. Decades ago, when I went from roll film to digital cameras (mid-1980's), I didn't know any better and shot in jpg format, which is a huge no-no because jpgs are a lossy format -- hence, now I have to get to the png format.

Thank you! :D

Nikki
User avatar
michel038
XnThusiast
Posts: 1291
Joined: Tue Sep 27, 2016 8:18 am
Location: France
Contact:

Re: Is there a way to export a jpg EXIF info?

Post by michel038 »

Thank you all
So the easiest way is method 2 , file listing

But XnViewMp allows to add a blank space close to the photos, containing various information found in metadata
(Tools, Batch convert, add action, Canvas resize relative, add text from .... )
... and save as png file
bubbalicious
Posts: 3
Joined: Sun Mar 21, 2021 1:36 pm

Re: Is there a way to export a jpg EXIF info?

Post by bubbalicious »

Thank you for your subsequent reply and using method 2 as the easiest, and that's the one I'll be using. I don't often post in user forums for help as I look in the program's user manual first for an answer, but there isn't a user manual, so this was the only way to get the answer to my question.

Have a great day! :D

Nikki
mrwul
Posts: 331
Joined: Tue May 25, 2010 7:01 pm

Re: Is there a way to export a jpg EXIF info?

Post by mrwul »

@michel038

Hello to you,

Many thanks for the solution with ExifTool!
3) Tools, Open with, Configure programs, Add .... browse the installation folder of XnViewMP, go to AddOn and select exiftool.exe
- Double click in first column and name it Exif2txt.
- Double click in 2nd column and add this parameters -k "-exif:all" -w txt
-Select some photos, right-click, Open with, Exif2txt ... close the exiftool window :
Text files with the same name as the photos with txt extension are created.
But with this method, you get a txt file for each photo
I wonder.. would there be a way to have a parameter that creates a .txt file
from IPTC Content:TItle -field followed by shoorting date-time

so, a combination of the title and date-time digitized.

With me the title field contains the description of the photo.
SnagIt-14102021 131153.png
SnagIt-14102021 131153.png (18.47 KiB) Viewed 1476 times
Thank you again!
User avatar
michel038
XnThusiast
Posts: 1291
Joined: Tue Sep 27, 2016 8:18 am
Location: France
Contact:

Re: Is there a way to export a jpg EXIF info?

Post by michel038 »

So, you want to get a txt file for each jpg ? ( if you want to change file names, use : Tools, Batch rename)

As described in the previous method, ExifTool can create such txt files, having the same name as the jpg files.
The content of these files can be chosen within the double quotes for Windows, single quote for Linux and MacOS
There are many fields containing dates, maybe the one I'm using is not the good one ...

creating Txt files containing iptc: title and date time digitzed

The parameter will be : -k "-iptc:headline" "exif:CreateDate" -w txt
or perhaps : -k "-iptc:headline" "DateTimeOriginal" -w txt
mrwul
Posts: 331
Joined: Tue May 25, 2010 7:01 pm

Re: Is there a way to export a jpg EXIF info?

Post by mrwul »

Thanks.
I tried various options, but regretfully it didn't work. I let it rest.
Bad luck.
Nonetheless, thanks again.
SnagIt-14102021 162300.png
SnagIt-14102021 162300.png (16.57 KiB) Viewed 1458 times
User avatar
michel038
XnThusiast
Posts: 1291
Joined: Tue Sep 27, 2016 8:18 am
Location: France
Contact:

Re: Is there a way to export a jpg EXIF info?

Post by michel038 »

Sorry, I made a mistake. :bugconfirmed:
Tags are preceded by a hyphen

The parameters must be : -k "-iptc:headline" "-exif:CreateDate" -w txt
or perhaps : -k "-iptc:headline" "-DateTimeOriginal" -w txt
mrwul
Posts: 331
Joined: Tue May 25, 2010 7:01 pm

Re: Is there a way to export a jpg EXIF info?

Post by mrwul »

Super!

The first one worked ( -k "-iptc:headline" "-exif:CreateDate" -w txt)
Didn't try the 2nd one, no reason to.

MANY thanks indeed!!

Really helpful.
Post Reply