Main Menu

Long list of files

Started by mtroja, October 07, 2019, 05:17:19 AM

Previous topic - Next topic

mtroja

Hello
I'm doing my first steps with the Exiftool and I want to read tags from a long list of specified files.
The command is about this:

"C:\Program Files\ExifTool\exiftool.exe" -f -s -d "%%d.%%m.%%Y %%H:%%M:%%S" "F:\Bilder\IMG-20190921-WA0001.jpg" ..................... "F:\Bilder\IMG-20190921-WA0300.jpg"  -Directory -FileName -DateTimeOriginal -CreateDate -FileCreateDate -k > "E:\tmp.txt"

"....................." means there are lot of filenames

The command ist written in a batch-file which I start from VBA. This works fine, but when the command is longer then 8191 characters there's a problem, because the commandline doesn't support such long commands.

I can write long arguments in an argfile via the "-@"-Tag. But this didn't work for the filelist.
Any solutions for the problem?

Thank you very much

mtroja

Phil Harvey

The -@ argfile does work for file lists.  Don't quote the file names.

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

mtroja

Perfect.
I quoted the filenames because of spaces in some foldernames, when I tried -@.
Without quotes it works.
Thank you very much for the quick help.
mtroja