Today, I encountered this problem and got depressed. Alas. Just nowProgramRun well. Suddenly, this error occurs.
I really don't know what's going on. The Internet is better. Baidu finally found a solution.
I used method 2 to solve my problem.
The error message is as follows:
Compiler error message: cs0016: failed to write to output file:'*: \ Windows \ Microsoft. NET \ framework \ v2.0.50727 \ temporary ASP. NET files \ *. dll'--Access denied."
Cause 1: permission issues and access permissions problems.
Solution 1: For the user netasp (Network Service [Window2003]) Set all permissions for the temp folder in Windows
Solution 2:
1If C:/If the temp folder does not exist in the Windows directory, create one;
2 Right-click the temp folder -- Attribute -- Security: Add a user " NETWORK SERVICE " , (For. NET Framework 1.0 Add a user " ASPnet user " ), " Grant permissions-full control;
3 , Right-click " My computer " - " Attribute " - " Advanced " - " Environment Variable " , Select " Temp " Click Edit to set the variable value % Systemroot % \ Temp, OK, then " TMP " Perform the same operation and click OK;
4Restart the IIS service to solve the problem.
Cause 2: the service is forbidden by some optimization software.
Solution:
1ASP. NET state service is stopped. Restart ASP. NET State service and set it to automatic.
2, Start-run-iisreset ;.
3OK