Moving away from publishing to folder on OneDrive to a local folder on the C: drive seems to work.
I also tried to change the rights to write to a folder on OneDrive, but it seems that applying new settings by unchecking "read only" folder attribute is not accepted.
Giving ALL users full rights does also not work.
Running VS in administrator mode also does not solve the problem.
So my conclusion is that ONEDRIVE is the BAD GUY!