Cannot figure out server.mapppath configuration

J

Jack

Hello,
I have an application on my desktop where I have hardcoded the connection
string. Now I need to move the application to our test webserver. Here I need
to use the server.mappath method to connect to the database. The database is
in the same directory as the new application named gwis. Hence the database
is in the gwis directory in the test webserver. I made the changes in my
connection string as follows:


myDSN="DRIVER={Microsoft Access Driver (*.mdb)}; "
'myDSN=myDSN & "DBQ=C:\_______GWISBRANDNEWREADY3\GMISDATA.mdb"
myDSN = myDSN & "DBQ=" & Server.MapPath("/gwisbrandnewready3/GMISDATA.mdb"
Set CN=server.createobject("ADODB.Connection")
CN.Open myDSN

Set RS = Server.CreateObject("ADODB.Recordset")
RS.ActiveConnection=CN

The old hardcoded string is commented out. However, with this change, the
application is not still working.
It goes through the verify.asp routine. However, it displays the following
message:

The page cannot be displayed
There is a problem with the page you are trying to reach and it cannot be
displayed.

HTTP 500 - Internal server error

Any help is appreciated in advance. Thanks.
 
P

Patrice

Disable "simplied http errors" in your IE config so that you see the exact
error...

Patrice
 
J

Jack

Thanks Bob for asking. Actually, my problem is resolved here. However,
I have a different problem which I posted in the database section which is
yet to
be resolved. It is about connecting from asp to a database located in a
different
server. Regards.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,020
Latest member
GenesisGai

Latest Threads

Top