PDA

View Full Version : Database Connection SNAFU


gorilla1
03-14-2003, 01:21 PM
I am using the code below to connect to my access database, which is in a folder called items. Now I want to connect from the parent directory of this folder. Seems like anything I try and I get page cannot be displayed or an internal server error. For instance, the following:
"=" & Server.MapPath("items/items.mdbDBQ")
does not work. How should this be done?

set conn = server.createobject("ADODB.Connection")
' conn.open "banner"
strConnString = "=" & Server.MapPath("items.mdbDBQ")
conn.open "DRIVER={Microsoft Access Driver (*.mdb)}; " & strConnString

..Well, this did work finally, as above.