在IIS / ASP.NET创建的物理文件夹虚拟应用程序/目录 [英] Creating virtual application/directory in physical folder on IIS/ASP.NET

查看:272
本文介绍了在IIS / ASP.NET创建的物理文件夹虚拟应用程序/目录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想实现的是简单的:

请注意,我的现场是一个空的网站,在这一堆文件夹,富,酒吧,巴兹等。

Notice that "my-site" is an empty website with a bunch of folders in it, "foo", "bar", "baz", etc.

所以,当我用鼠标右键单击富,然后选择新建>虚拟目录,并添加我的应用程序已经写在VS.NET,然后尝试浏览到的 HTTP://本地主机/富/上传我得到这个错误:

So when I right click on "foo" and choose "New > virtual directory" and add my application I've written in VS.NET and then try to navigate to http://localhost/foo/upload I get this error:

Parser Error Message: An error occurred loading a configuration file: Failed to 
start monitoring changes to 'C:\InetPub\my-site\foo\web.config' 
because access is denied.

问题是,有没有网络配置。在富-folder,它不应该,因为它是唯一在该网站正常的文件夹中。如果我添加虚拟目录在顶层,在比如的http://本地主机/ foo_upload ,一切正常,因为它应该。 ..所以,我究竟做错了什么?

The thing is, there is no web config. in the "foo"-folder, and it shouldn't since it's only a normal folder in the site. If I add the virtual directory at the top level, at say http://localhost/foo_upload, everything works as it should... so, what am I doing wrong here?

推荐答案

这听起来像一个权限问题,你的系统 - 一个.NET帐户的用户上下文ASP.NET运行在需要访问您的网站

It sounds like a permissions problem with your system - for a .NET account the user context ASP.NET runs in requires access to your site.

在系统到在Windows Server 2000这个用户是简单地称为ASPNET的本地帐户,后更改为NT_AUTHORITY帐户之一 - 最简单的方法来发现这是提供IIS WPG组(本地组)访问该帐户。

On systems up to Windows Server 2000 this user was a local account simply called ASPNET, after that is changed to one of the NT_AUTHORITY accounts - the easiest way to find this is to provide the IIS WPG group (a local group) with access to the account.

MS在 http://support.microsoft.com/kb/316721/ 提供的说明,使用上述确定哪些用户帐户,您应该检查访问。

MS provides instructions at http://support.microsoft.com/kb/316721/, use the above to determine which user account you should check access for.

这篇关于在IIS / ASP.NET创建的物理文件夹虚拟应用程序/目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆