Good morning,
I am very new to asp and database connections.
I'm trying to take a set of variables and write them to an access 2000 database. My database name, table name, variable and table column names are all correct as far as I can tell, but when I try to post the data to the database I get the following error:
Unable to post test data to host, cannot submit results! Server returned HTTP response code: 500 for URL: http://numdet01/courses/test/iron/submit.asp
The http path above is the correct path to the submit.asp file. Below is the text from this file:
<%
DIM addstuff
Set addstuff=Server.CreateObject("adodb.connection")
addstuff.ConnectionString="Provider=Microsoft.Jet. OLEDB.4.0;Data Source="&Server.MapPath("db/n395aeval.mdb") & "Persist Security Info=False"
addstuff.Open
varfinal_score=request.querystring("varfinal_score ")
employeeid=request.querystring("employeeid")
varelapsedtime=request.querystring("varelapsedtime ")
varcurrentdate=request.querystring("varcurrentdate ")
varcurrenttitlename=request.querystring("varcurren ttitlename")
varcurrenttitlename= Replace(varcurrenttitlename, "'", "~")
firstname=request.querystring("firstname")
firstname= Replace(firstname, "'", "~")
lastname=request.querystring("lastname")
lastname= Replace(lastname, "'", "~")
sqladd="INSERT INTO MAIN (varfinal_score,employeeid,varelapsedtime,varcurre ntdate,varcurrenttitlename,firstname,lastname) VALUES ('"&varfinal_score&"','"&employeeid&"','"&varelaps edtime&"','"&varcurrentdate&"','"&varcurrenttitlen ame&"','"&firstname&"','"&lastname&"')"
addstuff.execute(sqladd)
addstuff.Close
Set addstuff= Nothing
%>
Any suggestions would be most appreciated!
Thank you!