Compilation error CS0016: Could not write to output file

后端 未结 4 649
攒了一身酷
攒了一身酷 2020-12-06 16:45

In Brief

When I attempt to browse my website, I get the following error message:

CS0016: Could not write to output file \'c:\

4条回答
  •  难免孤独
    2020-12-06 17:03

    In IIS Manager, in the advanced settings of the Application Pool, make sure "Process Model > Load User Profile" is set to "True".

    I had this exact same problem. I tried changing permissions, disabling anti-virus, creating a new app pool, and reinstalling .NET. I even created a new site with just a "Default.aspx" page and tried to view that site. Even that site had the compilation error. Finally, I noticed that my app pools (clean test site and main site) had the non-default value "False" for the Load User Profile setting. I set that back to true and the issue went away.

提交回复
热议问题