Today, I encountered this problem and got depressed. Alas. The program runs properly just now. 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 the 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: Set all permissions for the temp folder in windows for the user netasp (Network Service [Window 2003 ])
Solution 2:
1. If no temp folder exists in the C:/Windows Directory, create one;
2. Right-click the temp folder -- properties -- Security, and add a user "network service" (If yes. net Framework 1.0 adds the user "ASPnet user"), "grant permissions -- full control;
3. Right-click "my computer"-"properties"-"advanced"-"environment variables", select "Temp" under system variables, and click Edit, set the variable value to % SystemRoot %/temp. OK. perform the same operation on "tmp" and click OK;
4. Restart the IIS service and solve the problem.
Cause 2: the service is forbidden by some optimization software.
Solution:
1. ASP. NET state service is stopped. Restart ASP. NET State service and set it to automatic.
2. Start-run-iisreset ;.
3. OK