I had problems on my current Windows 10 machine when doing cross platform mobile applications development in .NET.

Whenever I was trying to build or run an Android application in either Xamarin or Maui I got the following error message:

Error file not found: C:\Users\MagnusSundström\AppData\Local\Temp1sdflkjd322kjdj.tmp MyPrettyProject C:\Projects\MyPrettyProject\JAVAC 1

Turns out that Android (or Microsoft?) doesn’t like special characters. And since my last name contains the swedish letter Ö, I was down on my luck.

How to fix this?

After reaching out in various Microsoft and Android forums with little to no luck, out of the blue I received an email from a fellow developer with a solution to the problem.

In Windows default command prompt, run the following command:

mklink /D C:\Users\{faulty username from error message} C:\Users\{username with correct spelling}

So for me that would be:

mklink /D C:\Users\MagnusSundström C:\Users\MagnusSundström}

A Windows command prompt with text

We’ve now created a symbolic link. A symbolic link is a file system object that points to another file system object.

This solved the problem for me, and I am now able to run and build Android applications on my machine.

Mad props to Jeppe S for providing me with the above solution <3 People like you make me not lose my faith in mankind!