Local access to Access 2002

  • Thread starter Thread starter Steve
  • Start date Start date
S

Steve

I know how to access my 2002 database when it's on my wegsite, but when it's
stored in a local C: directory... I'm having problems. On the net I use:

<!--#include file="adovbs.inc"-->
<%
dim rs
dim conn

set conn = Server.CreateObject("ADODB.Connection")
conn.Open "calgarywebconcepts_Master"

set rs = Server.CreateObject("ADODB.Recordset")
rs.Open "Inventory", conn, adOpenStatic, adLockOptimistic, adCmdTable

ect...

Is there a way using a similiar method to access it locally (I want to use a
few of the many programs that I've written). Some code will be greatly
appreciated.

Thanks in advance... Steve
 
I forgot to mention that these files are stored in a directory in
C:\Inventory and the calgarywebconcepts_Master.mdb file is in a
sub-directory in the Inventory directory.
 
Are you in a situation where using linked tables is not available? If
so, why not?

Linked tables are set up in the Database "Tables" window.

In the Tables object, right click and select Linked Tables. Once
added, they work as any other table in the database.

Tom Ellison
Microsoft Access MVP
Ellison Enterprises - Your One Stop IT Experts
 
My problem isn't in accessing the tables. It's getting into the database in
the first place when it's set up on my local computer.
 
Dear Steve:

My response refers to having two separate databases, on a "back end"
containing data, and the other a "front end" which may not contain any
data itself at all, but has references to it.

I hope we will start actually communicating at some point, as I did
not really understand your original question, even though my response
may have had some validity anyway.

Tom Ellison
Microsoft Access MVP
Ellison Enterprises - Your One Stop IT Experts
 
Tom, Would I then not then have two databases with which I can't connect on
my local computer?

I've found some elementary code in an asp book which states the following:

<%
strConn="Provider=Microsoft.Het.OLEBD.3.51; Data Source=C\tmp\pubs.mdb"
%>
Then further down in opening a connection...

Set objConn=Server.CreateObject("ADODB.Connection")
objConn.Open.strConn

Although I haven't had a chance to experiment with this code yet... You can
see the reference to a local mdb file. This is what I am getting at. I need
some code similar to this (hopefully the correct code since the above
probably won't work with Access 2002) that will allow me to access my
database on my local machine.

There isn't too much that I don't know about accessing tables check out
http://www.calgarywebconcepts.com/Store/Store.asp
It's totally database dependant with 10 tables and built in search
capabilities. (But that's on the net... not on my local computer.)

Thanks...Steve
 
Back
Top