Hi,
I'm getting this error when i execute my asp file. This is a asp file with the POST method.
>Server.MapPath() error 'ASP 0173'
>
>Invalid Path Character
>
>/addkapvergunning(volledig).asp, line 16
>
>An invalid character was specified in the Path parameter >for the MapPath method.
>
The syntax of the asp file =
<%
' stap 0 variabelen aanmaken (hun scope = alleen in dit bestand)
dim cnDb
dim cmAddToDB
dim strInsertSQL
' Stap 3 Verbinding maken
set cnDB = Server.CreateObject("ADODB.Connection"
cnDB.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=" & Server.MapPath("\kapvergunning.mdb"
cnDB.open
' Stap 1 opvragen van velden
var_naam= Request.Form("naam"
var_naam= "'" & var_naam & "'"
var_adres= Request.Form("adres"
var_adres= "'" & var_adres & "'"
' Stap 2 SQL statement + Stap 1 opvragen van velden
strInsertSQL = "INSERT INTO kapvergunning(ondergetekende, adres) VALUES (" & var_naam & "," & var_adres & ""
' Stap 4 uitvoeren
set cmAddToDB = Server.CreateObject("ADODB.Command"
set cmAddToDB.ActiveConnection = cnDB
cmAddToDB.CommandText = strInsertSQL
cmAddToDB.Execute
' Stap 4B Alles weer legen
set cnDB = Nothing
set cmAddToDB = Nothing
%>
Don't get scared of the words I used. It's dutch...
I'm getting this error when i execute my asp file. This is a asp file with the POST method.
>Server.MapPath() error 'ASP 0173'
>
>Invalid Path Character
>
>/addkapvergunning(volledig).asp, line 16
>
>An invalid character was specified in the Path parameter >for the MapPath method.
>
The syntax of the asp file =
<%
' stap 0 variabelen aanmaken (hun scope = alleen in dit bestand)
dim cnDb
dim cmAddToDB
dim strInsertSQL
' Stap 3 Verbinding maken
set cnDB = Server.CreateObject("ADODB.Connection"
cnDB.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=" & Server.MapPath("\kapvergunning.mdb"
cnDB.open
' Stap 1 opvragen van velden
var_naam= Request.Form("naam"
var_naam= "'" & var_naam & "'"
var_adres= Request.Form("adres"
var_adres= "'" & var_adres & "'"
' Stap 2 SQL statement + Stap 1 opvragen van velden
strInsertSQL = "INSERT INTO kapvergunning(ondergetekende, adres) VALUES (" & var_naam & "," & var_adres & ""
' Stap 4 uitvoeren
set cmAddToDB = Server.CreateObject("ADODB.Command"
set cmAddToDB.ActiveConnection = cnDB
cmAddToDB.CommandText = strInsertSQL
cmAddToDB.Execute
' Stap 4B Alles weer legen
set cnDB = Nothing
set cmAddToDB = Nothing
%>
Don't get scared of the words I used. It's dutch...