Click to See Complete Forum and Search --> : ADODB.Connection trouble...help


cnl83
12-08-2004, 10:21 PM
Im having problems every time dsn.asp is accessed. This was part of a calendar program that I used on one server, but once transfered to the new server, I have problems getting this thing to work. can someone please help me out with this error.

ADODB.Connection.1 error '800a0bb9'

The application is using arguments that are of the wrong type, are out of acceptable range, or are in conflict with one another.

dsn.asp, line 6


Now the code thats in that ASP file is as follows.

<%
dim dsn
dim Conn
dsn="DBQ=" & Server.Mappath("admin/o12cal.mdb") & ";Driver={Microsoft Access Driver (*.mdb)};"
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open dsn
%>

russell
12-09-2004, 01:08 AM
two things:

1st: connection string should be:

"Driver={Microsoft Access Driver (*.mdb)};" &_
"Dbq=" & server.MapPath("admin/o12cal.mdb") & ";"
'' Line wrapped here to minimize horiz scrolling


2nd: is the mdb file in the correct directory?