Connecting Accesss to ASP

D

Des

Hi I have created in visual studio 6 an application using access 2000.
What I want to do is to put the database and asp on a website. I have
been told previously that I would not need to register the access
database (which would be difficult) and place the database in the same
fo;der as the asp pages, I need to know how to connect to the database
as there is no DSN no username or password.


Here is a segment of code that works localy on my own PC.


<%
dsn = "DSN=football"
Set connection = Server.CreateObject("ADODB.Connection")
Set rsWeeks = Server.CreateObject("ADODB.Recordset")
connection.Open dsn
sqlWeeks = "SELECT * FROM Weeks ORDER BY Week"
rsWeeks.Open sqlWeeks, connection
%>


Any help on this is appreaceated. Once the connection string is sorted
then it should fall into place.


Desmond.
 
B

Bob Barrows [MVP]

Des said:
Hi I have created in visual studio 6 an application using access 2000.
What I want to do is to put the database and asp on a website. I have
been told previously that I would not need to register the access
database (which would be difficult) and place the database in the same
fo;der as the asp pages, I need to know how to connect to the database
as there is no DSN no username or password.


Here is a segment of code that works localy on my own PC.


<%
dsn = "DSN=football"
Set connection = Server.CreateObject("ADODB.Connection")
Set rsWeeks = Server.CreateObject("ADODB.Recordset")
connection.Open dsn
sqlWeeks = "SELECT * FROM Weeks ORDER BY Week"
rsWeeks.Open sqlWeeks, connection
%>


Any help on this is appreaceated. Once the connection string is sorted
then it should fall into place.
http://www.aspfaq.com/show.asp?id=2126

Also see this article which explains the filesystem permissions that will
need to be set:
http://www.aspfaq.com/show.asp?id=2009


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

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,048
Latest member
verona

Latest Threads

Top