ASP vs ASP.NET

G

Guest

I’m using an ASP script on my website to access a database, which works fine.
When I try to access the same database using a ASP.NET script I get the
following error message:

The Microsoft Jet database engine cannot open the file '***'. It is already
opened exclusively by another user, or you need permission to view its data.

I know in general what this error message means, but since I don’t have any
influence on what my internet service provider does on the server I have no
idea what to do. Especially since it works using ASP but not using ASP.NET

Any help?

Chris
 
R

Rick Strahl [MVP]

Chris,

The problem is probably one of permissions. ASP.NET runs under a fairly
restrictive account (usually Network Service or whatever your ISP has
configured for your domain) and you need to make sure that this user has
access to the physical file on disk. Probably Read/Write access.

+++ Rick ---
 
B

Bob Barrows [MVP]

cnickl said:
I'm using an ASP script on my website to access a database, which
works fine. When I try to access the same database using a ASP.NET
script I get the following error message:

The Microsoft Jet database engine cannot open the file '***'. It is
already opened exclusively by another user, or you need permission to
view its data.

I know in general what this error message means, but since I don't
have any influence on what my internet service provider does on the
server I have no idea what to do. Especially since it works using ASP
but not using ASP.NET

Any help?

Chris

Just to add to Rick's reply: because it's a Jet database, the account needs
read/write access to the folder containing the database, not just the
database. In order for multi-user activity to be allowed, all users of a
database must be able to create, modify and delete the corresponding locking
file (dbname.ldb) in that folder.

In classic ASP, the account was called IUSR_machinename (and
IWAM_machinename for certain processes). In .Net, the account defaults to
the aspnet account. In both cases the administrator can configure IIS to use
a different account.

You need to contact your provider to get this corrected.

Bob Barrows
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,228
Members
46,818
Latest member
SapanaCarpetStudio

Latest Threads

Top