@mrjj

The QMessageBox shows the same temp. location as i can see when i run set in the commandline. Its the default TempLocation used by Windows ("C:/Users/<USER>/AppData/Local/Temp").
And this piece of code always fails to write to this location on this PC.

I will check for antivirus issues next time when i have access to this PC.