On my Windows 10 machine I am trying to run a "robocopy" command (from a .bat file) to backup files.
Everything is fine as long as the paths (to folders to backup) do not contain letters like ö, ü, ä which whoever is inevitable as this is a German environment.
Earlier I was able to fix this by sending a
chcp 1252
command first, so that the command prompt window runs on Code Page 1252 which has these characters. But this was on a Windows 7 machine then. (The default code page on this system is 850. It is a larger institutional network, and I have no administrator access.)
Now with the Windows 10 machine this does not have effect for me. The code page is set to 1252 (at least that's the return when you ask "chcp"), and still the robocopy command does not run.
Here is my robocopy command:
robocopy C:\Users\Myself\Documents\Notizbücher Y:\RobocopyBackups\001_NotizbücherBackup /e /mir /np /z /tee /log:Y:\RobocopyBackups\001_Backup_log.txt
When I run this, the "ü" in "Notizbücher" always gets messed up, and of course the command cannot be run since the computer does not find the (messed up) address.
I tried all sorts of things
Sending first chcp 1252
Making sure that my .bat file where I keep the code is encoded as Windows-1252 (I am using Notepad++)
Trying chcp 65001 for UTF-8 (with and without encoding the .bat file similarly)
Trying chcp 2851 for ISO-8859-1, just for fun...
It's always the same: the "ü" gets messed up.
Of course I could just remove the "ü" from the folder names. But I want to have a clean solution, not such a lame workaround.
What could I do?