This topic is locked

database in external directory

8/30/2007 6:16:58 AM
ASPRunnerPro General questions
4
4thninches author

Hi,
My host has a directory for each domain called 'data' and asks users to put .mdb databases in the 'data' directory...
How can I change dbconnection.asp to find a path to that folder?
Host tells me the path should be -
D:\websites\accountname\data\databasename.mdb
So I change it reflect the relevant account and file name.
But the page give the error 'The Path parameter for the MapPath method must be a virtual path. A physical path was used.'
When built - dbconnection.asp points to - db\database.mdb
Help please
FAI

D
dunga 8/30/2007

create a file whereami.asp with the following code:
<%

Response.Write Request.ServerVariables("PATH_INFO")

%>
exceute the file as you usually access the web asp page from the computer.
it will give you the path to put BEFORE the databasename.mdb

Sergey Kornilov admin 8/30/2007

Check this article that explains how to build a connection string:

http://xlinesoft.com/asprunner/docs/troubl...ery__errors.htm