I am trying write a python script that runs an external program automatically by clicking buttons and give keyboard input (usually file paths) with pyautogui. Now if I try use the funktion pyautogui.typewriter(filepath) it always types the backslashes as questionmarks. This minimal example:
pyautogui.typewrite('\\')
returns simply ?
Now, if I change my keyboard layout in the system settings to english, it correctly returns \
My default layout is german, and I cant really change that because this messes up the later stages of the program due to wrong date formats. Any ideas how to solve this problem?