This page looks plain and unstyled because you're using a non-standard compliant browser. To see it in its best form, please upgrade to a browser that supports web standards. It's free and painless.

Spatial

首页 | 资源中心 | 管理控制台

« | »

server2003+ii6 编译器错误信息:CS0016: 未能写入输出文件解决方案

sdhjl2000 | 31 三月, 2007 20:46

安装Quick Start后出现错误CS0016,解决方法:
1,重新安装试试。
2,修改windowstemp及Temporary ASP.NET Files文件夹的权限使net services具有写入修改权限。
转:
http://andyamy.spaces.live.com/blog/cns!9BBA60FE7660AD3D!120.entry

解决:编译器错误信息: CS0016: 未能写入输出文件“c:WINDOWSMicrosoft.NETFrameworkv1.1.4322Temporary ASP.NET Fileslistenleaksae3daa38e9fdb67zaie9ij.dll”--“拒绝访问。 ”

一、http://support.microsoft.com/default.aspx?scid=kb;en-us;329065#

PRB: Access Denied Error When You Make Code Modifications with Index Services Running

RESOLUTION

If you do not use Index Server on the server, you can disable it. To do so, follow these steps:
1. Click Start, and then click Services.
2. Locate Indexing Service from the list of services, and then click Indexing Service Properties from the subform.
3. On the General tab of the Indexing Service Properties dialog box, in the Startup type drop-down item list, click Disabled.
4. Click OK.

If you use Index Server, you can exclude the Temporary ASP.NET Files directory from the folders that the Index Server scans. To do so, follow these steps:
1. Click Start, point to All Programs, point to Administrative Tools, and then click Computer Management.
2. Expand the Services and Applications node, expand the Indexing Service node, and then expand the System node.
3. Right-click the Directories folder, point to New, and then click Directory from the subform to open the Add Directory dialog box.
4. Click Browse, and then locate the Temporary ASP.NET Files directory. You typically find the Temporary ASP.NET files in the following path: c:<WINDIR>Microsoft.NETFramework<Version Number>Temporary ASP.NET Files
Note<Version Number> is the version of .NET Framework installed on your computer.
5. Click No under the Include in Index? option buttons.
6. Click OK to close.
7. Close the Computer Management dialog box.
8.

Restart the Indexing Services service.

二、

另外还有一个 Access denied 的错误说是不能访问 C:WINDOWSMicrosoft.NETFrameworkv1.1.4322Temporary ASP.NET Files 下的某个目录。产生这些错误的原因很多,主要的可能包括:Bin 目录或者 Web.config 被更改以及访问文件系统的权限不够。

如果 Bin 目录或者 Web.config 被更改,MSDN 网站上有文章说是因为 Microsoft Index Services(Indexing Service) 服务在运行。详细内容可以访问: PRB: Access Denied Error When You Make Code Modifications with Index Services Running

但是另外还需要注意一些别的问题,

  • 检查 Bin 目录的文件系统访问权限。一般只要确保 Users 容器拥有“读取和运行”、“列出文件夹目录”和“读取”的权限就可以了。
  • 如果提示说不能访问 C:WINDOWSMicrosoft.NETFrameworkv1.1.4322Temporary ASP.NET Files... ,可以将 Temporary ASP.NET Files 目录的访问权限列表中添加 Everyone,并设置为拥有所有的权限。然后在访问一次此 Web 应用程序后,将 Temporary ASP.NET Files 目录的访问权限列表中将 Everyone 删除就可以了。

综上所述的方法,主要包括:

  • 禁用或设置 Indexing Service 服务;
  • 检查 Bin 目录的访问权限;
  • 设置 Temporary ASP.NET Files 目录的访问权限。

三、在 Windows2003 下(IIS6),用 VS2003 生成一个 asp.net 应用,然后 F5 进行调试,出现如下错误信息:

“/0124”应用程序中的服务器错误。

编译错误 说明: 在编译向该请求提供服务所需资源的过程中出现错误。请检查下列特定错误详细信息并适当地修改源代码。

编译器错误信息: CS0016: 未能写入输出文件“e:WINDOWSMicrosoft.NETFrameworkv1.1.4322Temporary ASP.NET Files124fea90a4b69167562pw09que0.dll”--“拒绝访问。 ”
源错误:版本信息: Microsoft .NET Framework 版本:1.1.4322.2032; ASP.NET 版本:1.1.4322.2032

我于是用“WINDOWSMicrosoft.NETFrameworkv1.1.4322Temporary ASP.NET Files”在msdn以及网上搜了一把,搜到两种解决方案:

修改该目录的权限,加上“NETWORK SERVICE”,让它对该目录有控制权限。
修改IIS服务的缺省账户为“本地系统”
经验证,方法二可行,方法一失败。(yzt_andyamy采用方法一却成功了!)但是方法二会导致IIS运行不安全,所以这种方法不太合适。

后来我查看了别人的配置,发现人家IIS服务的缺省账户都是“网络服务”,这就说明我的机器的权限设置在某个地方存在差异。但是问题出在哪里呢?我遍查MSDN和Google/baidu也没有找到答案。

后来不知道抽了哪根筋,灵光一闪,看看 WindowsTemp 的权限设置,把 “NETWORK SERVICE”的权限设置为“控制”级别,再试试Debug,成了!

真是见鬼!难道说这是Windows的一个BUG?还是我的哪个地方的设置出现了问题?

==上面是一个GG的BLOG,偶按照他的方法,设置了 WindowsTemp 的权限,结果好了。
莫名其妙。


[url=][/url] [回复]

[url=][/url]

aalqm | 02/01/2008, 17:56

[url=][/url] [回复]

[url=][/url]

ckgnkk | 03/01/2008, 00:33

Nice work [回复]

Hi webmaster. Nice Work! :-) lol

Effefespeak | 04/10/2008, 10:41

If You want to delete your site from my base [回复]

to: Admin - If You want to delete your site from my spam list, please sent url of your domain to my e-mail: stop.spam.today@gmail.com
And I will remove your site from my base within 24 hours
webmastegz

nilesnawclaig | 17/11/2008, 02:32

My girlfriend gave me an STD! [回复]

I've been dealing with the same girl for the last 3 years. Very beautiful young lady, working on her Master's Degree. Last week I went to the doctor for my annual check up . So they got a sample of my blood and I told the doctor to check it for everything. Come to find out, I have a STD . I am pass UPSET ! I've been dealing with the same lady for some time now...how should I approach this ? I already asked her has she ever been with someone else during our time together. I am completely amazed wth this situation....... :-(

ledatonyneelt | 08/01/2010, 18:20

发表评论

标题

在此添加评论

称呼

邮箱地址(可选)

个人主页(可选)




Valid XHTML 1.0 Strict and CSS.
Powered by pLog
Design by Book of Styles