Posted on 2002-07-11
I have the following database conncetion code that I reference with an INCLUDE file.
ScriptName = Request.ServerVariables("SCRIPT_NAME")
ScriptNameParts = Split(ScriptName, "/", -1)
ScriptName = ScriptNameParts(Ubound(ScriptNameParts))
BaseLoc = Left(Request.ServerVariables("PATH_TRANSLATED"), Len(Request.ServerVariables("PATH_TRANSLATED"))-Len(ScriptName))
DBase = "databases/supplier.mdb"
DBasePath = BaseLoc & DBase & ";"
strProvider="Driver=Microsoft Access Driver (*.mdb); DBQ=" & DBasePath
set objConn = server.createobject("ADODB.Connection")
It works perfectly in a normal environment, however I've now tried using it in an environment where the folder databases (within the DBase = "databases/supplier.mdb" line) is a virtual directory.
It now gives me the following error :
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Microsoft Access Driver] '(unknown)' is not a valid path. Make sure that the path name is spelled correctly and that you are connected to the server on which the file resides.
/include/supplierConnString.asp, line 15
Any ideas ?????????