ExifTool Forum

ExifTool => Newbies => Topic started by: Juana on July 05, 2018, 05:41:50 AM

Title: German Character Problem in folders
Post by: Juana on July 05, 2018, 05:41:50 AM
Hi,

searched through the forum and FAQs but couldn't find help there.  ::)
I am using exif tool in batch mode on a windows 10 PC. Processing jpg, CR2, Tiff and RW2 images. Works fine btw  ;D, exept:

If a Folder contains a german Charakter, the Folder is not processed.
e.g.
X:\München
("C:\EXIFTOOL\exiftool.exe" -keywords+="Winter" "X:\München\2")

If I change it to X:\Munchen (in .bat and the folder name) it works fine.
As the window disappears so quickly, I cannot read the error message, but I believe its something like "Error: not found"
München appears like that M³nchen.

Additionally, I cannot set any german Charakters (äöüß) in the metadata.

Is there a setting to make this work?


Best Regards Juana
Title: Re: German Character Problem in folders
Post by: Phil Harvey on July 05, 2018, 07:22:19 AM
Hi Juana,

Did you read this (https://exiftool.org/exiftool_pod.html#WINDOWS-UNICODE-FILE-NAMES)?

(This is also mentioned under point 1 of FAQ 10)

- Phil
Title: Re: German Character Problem in folders
Post by: Juana on July 05, 2018, 12:42:35 PM
Hi Phil,

thanx for the reply. Yes I did.

How would I put this in my batch?
(this is the snippet: C:\EXIFTOOL\exiftool.exe" -keywords+="Winter" "X:\München\2)
And: would it solve the problem with the folders?

Best Regards

Juana


Title: Re: German Character Problem in folders
Post by: Phil Harvey on July 05, 2018, 12:57:56 PM
Hi Juana,

I don't know about how Windows handles character encoding in .bat files.

The best solution is to use an ExifTool -@ argfile encoded in UTF-8 containing the directory name(s), and add -charset filename=utf8 to your command.

- Phil
Title: Re: German Character Problem in batch files
Post by: Juana on July 06, 2018, 04:32:06 AM
Hi Phil,

thanx for giving me the right hint. The solution is to change the codepage to (1252 Latin).

Just add this as first row of the batch file:
chcp 1252

and it works perfektly.
Thanx again :-D (and for your great tool, I love it ;D)

Best Regards

Juana
Title: Re: German Character Problem in folders
Post by: Juana on July 26, 2018, 02:25:05 PM
Hi, sorry, for digging this out again.

The folders with umlaut work perfectly :-), but

I read through all Faq and tried all options of other forum posts, but it still wont work:

No matter if I use the batch file or the command line itself, it is not possible to write the -title with an Umlaut.
I tried to change the codepage to Latin 1, Latin2 or UTF8. I tried to add -l, -codedcharacterset=utf8 or -charset iptc=utf8 (for iptc and exif). But St. Bartholomäus always ends up as St. Bartholom?us. I tried it on jpgs, RW2 and CR2, all the same.

what else could I try?

Title: Re: German Character Problem in folders
Post by: StarGeek on July 26, 2018, 02:49:15 PM
Quote from: Juana on July 26, 2018, 02:25:05 PMI tried to add -l

Try the -L option (https://exiftool.org/exiftool_pod.html#L--latin) (uppercase, not lowercase L).

I have always had problems with windows and alternative characters, especially in batch files.  If the -L option (https://exiftool.org/exiftool_pod.html#L--latin) doesn't work,  I usually just throw my hands up in despair and use the -E option (https://exiftool.org/exiftool_pod.html#E--ex--escapeHTML--escapeXML) and html entities.  For example:

C:\>exiftool -P -overwrite_original -E -xmp:title="Ä, ä, Ë, ë, Ï, ï, Ö, ö, Ü, ü, Ÿ, and ÿ" y:\!temp\Test3.jpg
    1 image files updated

C:\>exiftool -g1 -a -s -xmp:title -L y:\!temp\Test3.jpg
---- XMP-dc ----
Title                           : Ä, ä, Ë, ë, Ï, ï, Ö, ö, Ü, ü, Ÿ, and ÿ


HTML online converter (http://www.online-toolz.com/tools/text-html-entities-convertor.php) I just used for this.
Title: Re: German Character Problem in folders
Post by: Juana on July 28, 2018, 03:50:10 AM
The capital -L worked. Thank you so much!!!
Saved my weekend  8)

Just in case, to be on the safe side:

I write the wantet title in the HTML converter and use it with your command in the first line, correct?