If I can't get the web host to set up a DSN for my web page, How do I create a connection to my database using ADO?
(I do know its relative path to the db).
Dim c
set c = Server.CreateObject("ADODB.Connection"
'TODO: change directory when locally testing
c.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("yourdbname.mdb"
you can change the server.mappath to the fully qualified path to your DB, if you'd like leo
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.