无法从ASP.NET应用程序中打开访问数据库 [英] Cannot open an access database from within an ASP.NET application

查看:71
本文介绍了无法从ASP.NET应用程序中打开访问数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好:


当我尝试使用Access数据库时,我遇到以下异常:


'/'中的服务器错误WebGrid''应用程序。

------------------------------------- -------------------------------------------

Microsoft Jet数据库引擎无法打开文件''D:\Program

Files \ Infragistics \ NetAdvantage 2005 Volume

2 \ _ASP .NET\Samples\Data\samplebrowser.mdb'。它已被其他用户专门打开

,或者您需要获得查看其数据的权限。


我确保文件夹Data具有完全访问权限对于这两个结果,

< machine_name> \ aspnet和< machine_Name> \ IWAM_machine_name


有人可以告诉我如何解决这个问题?谢谢。


Venki

Hello:

When I tried to use an Access database, I get the following exception:

Server Error in ''/WebGrid'' Application.
--------------------------------------------------------------------------------

The Microsoft Jet database engine cannot open the file ''D:\Program
Files\Infragistics\NetAdvantage 2005 Volume
2\ASP.NET\Samples\Data\samplebrowser.mdb''. It is already opened exclusively
by another user, or you need permission to view its data.

I made sure that the folder, Data, has full access to these two accouhts,
<machine_name>\aspnet and <machine_Name>\IWAM_machine_name

Can somebody tell me how I can resolve this issue? Thanks.

Venki

推荐答案

1)

数据库是否打开?

如果您在Access中打开数据库,您将收到此异常。

因此,如果您打开数据库,请关闭它并再试一次。


2)

如果您确定没有打开数据库,请检查它是否正确关闭



当您打开Access数据库文件进行编辑时,它会创建一个临时文件

,名为samplebrowser.idb。

当您关闭数据库时,该文件disapears。

如果它仍然存在,数据库可能没有正确关闭,请尝试关闭

再次


3)最后


尝试将持久性设置为IUSR_< machine_name>,

用户IIS使用。

如果您不确定,请设置为完整每个人的权限只是加入


HTH


" vvenk" < VV *** @ discussions.microsoft.com>在消息中写道

新闻:C1 ********************************** @ microsof t.com ...
1)
Is the database open?
If you have the database open in Access, you will get this exception.
So if you have the database open, close it and try again.

2)
If your sure you don''t have the database open, check that its closed
properly.
When you open an Access database file for editing, it create a temp file
called "samplebrowser.idb".
When you close the database, that file disapears.
If its still there, the database may have not closed properly, try closing
it again

3) Lastly

Try setting persmissions to IUSR_<machine_name>,
thats the user IIS uses.
If you not sure, set full permissions to everyone just incase

HTH

"vvenk" <vv***@discussions.microsoft.com> wrote in message
news:C1**********************************@microsof t.com...
您好:

当我尝试使用Access数据库时,出现以下异常:

服务器错误''/ WebGrid''申请。
-------------------------------------- ------------------------------------------

Microsoft Jet数据库引擎无法打开文件''D:\Program
Files \ Infragistic \ NetAdvantage 2005卷
2 \ ASPP.NET \Samples \Data\samplebrowser.mdb ''。它已被其他用户专门打开
,或者您需要获得查看其数据的权限。

我确保文件夹Data可以完全访问这两个用户,
< machine_name> \ aspnet和< machine_Name> \ IWAM_machine_name

有人可以告诉我如何解决这个问题吗?谢谢。

Venki
Hello:

When I tried to use an Access database, I get the following exception:

Server Error in ''/WebGrid'' Application.
--------------------------------------------------------------------------------

The Microsoft Jet database engine cannot open the file ''D:\Program
Files\Infragistics\NetAdvantage 2005 Volume
2\ASP.NET\Samples\Data\samplebrowser.mdb''. It is already opened
exclusively
by another user, or you need permission to view its data.

I made sure that the folder, Data, has full access to these two accouhts,
<machine_name>\aspnet and <machine_Name>\IWAM_machine_name

Can somebody tell me how I can resolve this issue? Thanks.

Venki



文件夹&文件。

另外,检查你的IIS设置,你使用匿名或集成的

安全性吗?这决定了你需要为权限设置的用户。


-

Curt Christianson

网站: http://www.darkfalz.com

博客: http://blog.darkfalz.com


" vvenk"写道:
Folder & File.
Also, check your IIS settings, are you using anonymous or integrated
security? That determins the user you need to set for permissions.

--
Curt Christianson
site: http://www.darkfalz.com
blog: http://blog.darkfalz.com

"vvenk" wrote:
您好:

当我尝试使用Access数据库时,我遇到以下异常:

服务器错误''/ WebGrid''申请。
-------------------------------------- ------------------------------------------

Microsoft Jet数据库引擎无法打开文件''D:\Program
Files \ Infragistic \ NetAdvantage 2005卷
2 \ ASPP.NET \Samples \Data\samplebrowser.mdb ''。它已由其他用户专门打开,或者您需要获得查看其数据的权限。

我确保文件夹Data可以完全访问这两个用户,< machine_name> \ aspnet和< machine_Name> \ IWAM_machine_name

有人可以告诉我如何解决这个问题吗?谢谢。

Venki
Hello:

When I tried to use an Access database, I get the following exception:

Server Error in ''/WebGrid'' Application.
--------------------------------------------------------------------------------

The Microsoft Jet database engine cannot open the file ''D:\Program
Files\Infragistics\NetAdvantage 2005 Volume
2\ASP.NET\Samples\Data\samplebrowser.mdb''. It is already opened exclusively
by another user, or you need permission to view its data.

I made sure that the folder, Data, has full access to these two accouhts,
<machine_name>\aspnet and <machine_Name>\IWAM_machine_name

Can somebody tell me how I can resolve this issue? Thanks.

Venki



Curt:


在网站上安全设置,Enable_Anonymous_Access被检查,并且

它使用帐户IUSER_< machine_Name>进入。并且,我确保此帐户具有完全访问权限




此外,还会检查集成Windows身份验证。

Venki


" Curt_C [MVP]"写道:
Curt:

In the website''s security setting, Enable_Anonymous_Access is checked and
the it uses the account IUSER_<machine_Name> for access. And, I made sure
that this account has full access rights.

Also, Integrated Windows Authentication is checked as well.

Venki

"Curt_C [MVP]" wrote:
Folder&文件。
另外,检查您的IIS设置,您使用的是匿名还是集成
安全性?这决定了你需要为权限设置的用户。

-
Curt Christianson
网站: http://www.darkfalz.com
博客: http://blog.darkfalz.com

vvenk写道:
Folder & File.
Also, check your IIS settings, are you using anonymous or integrated
security? That determins the user you need to set for permissions.

--
Curt Christianson
site: http://www.darkfalz.com
blog: http://blog.darkfalz.com

"vvenk" wrote:
您好:

当我尝试使用Access数据库时,我遇到以下异常:

服务器错误''/ WebGrid''申请。
-------------------------------------- ------------------------------------------

Microsoft Jet数据库引擎无法打开文件''D:\Program
Files \ Infragistic \ NetAdvantage 2005卷
2 \ ASPP.NET \Samples \Data\samplebrowser.mdb ''。它已由其他用户专门打开,或者您需要获得查看其数据的权限。

我确保文件夹Data可以完全访问这两个用户,< machine_name> \ aspnet和< machine_Name> \ IWAM_machine_name

有人可以告诉我如何解决这个问题吗?谢谢。

Venki
Hello:

When I tried to use an Access database, I get the following exception:

Server Error in ''/WebGrid'' Application.
--------------------------------------------------------------------------------

The Microsoft Jet database engine cannot open the file ''D:\Program
Files\Infragistics\NetAdvantage 2005 Volume
2\ASP.NET\Samples\Data\samplebrowser.mdb''. It is already opened exclusively
by another user, or you need permission to view its data.

I made sure that the folder, Data, has full access to these two accouhts,
<machine_name>\aspnet and <machine_Name>\IWAM_machine_name

Can somebody tell me how I can resolve this issue? Thanks.

Venki



这篇关于无法从ASP.NET应用程序中打开访问数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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