Are you getting the same error with that code? What kind of comment do you
expect? See inline:
Utada P.W. SIU wrote:
but i had used dsn-less already, here's my code
function get_connection()
dim connection
dim cnString
cnString = "PROVIDER=MICROSOFT.JET.OLEDB.4.0;" & _
"DATA SOURCE=" & server.mappath("..\projects\lib\db\data.mdb") &
";"
The & ";" is not hurting anything but it is not needed.
If you are having a problem here, I suspect it is because you are using \ in
your url instead of /. Try:
"DATA SOURCE=" & server.mappath("../projects/lib/db/data.mdb")
If that still produces an error, do
Response.Write cnString
and verify that the path produced is the valid path to your database. Also,
verify that the IUSR_machine account has Change permissions for the folder
containing your database. It needs to create, modify and delete the database
lock file (data.ldb) to permit multiuser activity.
HTH,
Bob Barrows
--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"