MSaccess

huby

Freshman
Joined
Feb 20, 2004
Messages
32
hello, quick question :

is it possible to use msAccess in a web application, using a relative path ? my client would like to manage his data locally with access, and update one single file via FTP when he feels like it (and the web application would read that file, obviously). the web app is not on my machine, nor his. it is within a hosting company.

when i create a connection string to an access database, visual studio requires a full path "c:\ ...\data\db1.mdb" whereas i'd like to be able to set "data/db1.mdb"

any hints on this ? is it possible at all ?

thank you,

Huby.
 
Use Server.MapPath("data/db1.mdb")
try putting ur mdb file in the root directory of your web application (in the bin it didn't work for me)
 
fadi said:
Use Server.MapPath("data/db1.mdb")
try putting ur mdb file in the root directory of your web application (in the bin it didn't work for me)

Please do not put your mdb file in web directory (wwwroot) or it's subdirectory, for security reason.
 
bungpeng said:
Please do not put your mdb file in web directory (wwwroot) or it's subdirectory, for security reason.

You can generally put your mdb file anywhere (except the root) but remember to give the folder read/write permissions or it wont work!
 
Remember this: if you put the mdb file under web folder, then user able to download your 'database'!
 
Back
Top