473,511 Members | 9,983 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problems accessing an MS Access 2000 DB in ASP

Our graphic designer is developing our new company website. We have switched
providers and currently she is working on the new website which currently
ressides on the new providers server as they support the ASP development
environment. Their server is a Win2K3 server.

She is writing an ASP module to connect to an MS Access 2000 database and is
having problems connecting. In this database there is only one table.

She has tried many different connection strings all to no avail and then
found from investigating that the best and fastest method is to use the OLE
connection string. However, each time she runs the ASP code she gets the
following error...

----------------------------------------------------------------------------
--------
Microsoft JET Database Engine error '80004005'

You do not have the necessary permissions to use the
'E:\Files\LocalUser\truenorth\NewFiles\models.mdb' object. Have your system
administrator or the person who created this object establish the
appropriate permissions for you.

/NewFiles/db_simple2.asp, line 14
----------------------------------------------------------------------------
--------

We have asked the provider to make sure that the NTFS file privs have been
set appropriately on the directory this db is in, and they have informed us
that it has been. I use Access here at work, and I can generate this error,
if I have forgotten to give a user "open/run" rights on the actual
database - using the 'Security' settings. But, we use a workgroup
information file (.mdw) file here at work. Typically if you do not specify
the workgroup file the default user of admin is used - which has full access
to the DB. However, if our provider does not have Access installed on their
server - which they likely do not, then there would be no default system.mdw
file - and then how would you connect to the db and get any privs at all?
Does anyone have any clue what might be happening here? Do we need to
specify a system file in the db connection string and also specify a
username/password to connect with? And, if so, does anyone have the proper
syntax for doing so?

The ASP code she is using is shown below...

----------------------------------------------------------------------------
-----
Dim cnnDB ' ADO connection
Dim rstDB ' ADO recordset
Dim strDBPath ' path to Access database (*.mdb) file
Set cnnDB = Server.CreateObject("ADODB.Connection")
Set rstDB = Server.CreateObject("ADODB.Recordset")

' path to Access 2000 database on Internet providers server
strDBPath = Server.MapPath
("E:\Files\LocalUser\truenorth\NewFiles\database\m odels.mdb")

cnnDB.Open "Data Source=" & strDBPath & ";Provider=Microsoft.Jet.OLEDB.4.0;"

Set rstDB = cnnDB.Execute("SELECT * FROM models")

Do While Not rstDB.EOF
rstSearch.Fields("modelfolder")
rstSearch.Fields("modeltotal")
rstSearch.Fields("modeltype")

rstDB.MoveNext

Loop

rstDb.Close

Set rstDB = Nothing

cnnDB.Close

Set cnnDB = Nothing
Jul 19 '05 #1
1 2128
Brad Pears wrote:
Our graphic designer is developing our new company website. We have
switched providers and currently she is working on the new website
which currently ressides on the new providers server as they support
the ASP development environment. Their server is a Win2K3 server.

She is writing an ASP module to connect to an MS Access 2000 database
and is having problems connecting. In this database there is only one
table.

She has tried many different connection strings all to no avail and
then found from investigating that the best and fastest method is to
use the OLE connection string. However, each time she runs the ASP
code she gets the following error...

-------------------------------------------------------------------------- -- --------
Microsoft JET Database Engine error '80004005'

You do not have the necessary permissions to use the
'E:\Files\LocalUser\truenorth\NewFiles\models.mdb' object. Have your
system administrator or the person who created this object establish
the appropriate permissions for you.

/NewFiles/db_simple2.asp, line 14
-------------------------------------------------------------------------- -- --------

We have asked the provider to make sure that the NTFS file privs have
been set appropriately on the directory this db is in, and they have
informed us that it has been.


The IUSR_machinename account needs read/write permissions on the folder
containing the database file. If you are connecting in a Session or
Application event, or the application protection is set to high, then the
IWAM_machinename account also needs those permissions.

The person setting up the security for your database can verify that the
appropriate permissions are set by logging into the machine using the IUSR
account and verifying that he can create and delete a text file in the
database folder.

Bob Barrows

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Jul 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
13635
by: PW | last post by:
Hi, I'm using WinXP-Pro, ASP classic, IIS 5.0. I regularly get this error, but I know I am the only user accessing the website at the time of the error. I looked it up on the MS support...
4
2283
by: David | last post by:
Hi, I want to work with Access 2002. I will need to be able to distribute my application to users that may still have access 2000 on their computers. I know access 2002 has a function that...
4
3499
by: James | last post by:
I have a VB windows forms application that accesses a Microsoft Access database that has been secured using user-level security. The application is being deployed using No-Touch deployment. The...
1
650
by: James | last post by:
I have a VB windows forms application that accesses a Microsoft Access database that has been secured using user-level security. The application is being deployed using No-Touch deployment. The...
4
1281
by: Fred Nelson | last post by:
Help! I just upgraded MSDE to the latest version on my Windows 2000 server. Everything appears to work fine - the enterprise manager on both the server and on my computer are able to access the...
5
3895
by: Mike | last post by:
I'm having trouble accessing SQL2005 Standard Edition as a second instance of SQL Server where the first instance is SQL 2000 Enterprise Edition. I installed SQL 2005 as a named instance...
5
4705
by: terryc | last post by:
Hi Guys I've set up a web app on my machine using IIS and XP Pro. I can access the site using my machine (http://localhost/appName) no problems, but when I try and access this app using another...
4
2324
by: ThePhenix | last post by:
Hi everybody, I have recently been doing a conversion for my boss for a access 2000 database (both front and backend) to a MSSQL backend. I finished the conversion today (as quite a lot of the...
8
7269
by: John | last post by:
Hi We had an sbs 2003 with isa 2000 server. We wre able to access a remote sql server (hosted at our web host) just fine. We replaced the server with a new sbs 2003 r2 with isa 2004 server and...
0
7251
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7148
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7367
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7430
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5673
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3230
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3217
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1581
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
790
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.