INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: MC Commands don't like accented characters in filenames  (Read 528 times)

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
MC Commands don't like accented characters in filenames
« on: February 03, 2021, 06:17:35 am »

MC appears to have no problem handling media filenames that contain accented characters, but the same cannot be said for the MC Commands. The batch file shown below ignores the three filenames containing accented characters. Only the first two files are added to Playing Now.

Is there a way to bypass this problem without renaming the affected files?

Code: [Select]
@echo off
MC27.exe /Mode Mini
MC27.exe /Play "G:\....\01 I. [Chorus] 'O ewiges Feuer, o Ursprung der Liebe'.dsf"
MC27.exe /Play "G:\....\02 II. Recitativo 'Herr, unsre Herzen halten dir' (Tenore).dsf"
MC27.exe /Play "G:\....\03 III. Aria 'Wohl euch, ihr auserwählten Seelen' (Alto).dsf"
MC27.exe /Play "G:\....\04 IV. Recitativo 'Erwählt sich Gott die heilgen Hütten' (Basso).dsf"
MC27.exe /Play "G:\....\05 V. Tutti. Friede über Israel.dsf"
Logged

zybex

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2618
Re: MC Commands don't like accented characters in filenames
« Reply #1 on: February 03, 2021, 07:54:23 am »

Try adding "chcp 65001" to the 2nd line of your .bat file to force UTF8 encoding.
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: MC Commands don't like accented characters in filenames
« Reply #2 on: February 03, 2021, 08:32:50 am »

Try adding "chcp 65001" to the 2nd line of your .bat file to force UTF8 encoding.

Many thanks for that. It does indeed resolve my problem!   :)

Does that change of Code Page only apply within the batch file?

Logged

zybex

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2618
Re: MC Commands don't like accented characters in filenames
« Reply #3 on: February 03, 2021, 10:11:56 am »

Yes. It's possible to make it the default codepage, but I don't recommend it - other apps may have problems with that.
Logged

haggis999

  • Citizen of the Universe
  • *****
  • Posts: 514
Re: MC Commands don't like accented characters in filenames
« Reply #4 on: February 03, 2021, 11:38:56 am »

Yes. It's possible to make it the default codepage, but I don't recommend it - other apps may have problems with that.

That's the answer I was hoping for. I just wanted to be sure that such a batch file entry wouldn't cause issues elsewhere.

Thanks again for your rapid resolution to my problem.
Logged
Pages: [1]   Go Up