recordset, addnew, update
HVAD ER DER GALT HER??<%
Dim Cn
Set Cn = Server.CreateObject(\"ADODB.Connection\")
Cn.Open \"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=\" & Server.MapPath (\"database.mdb\")
Dim rsNews
Set rsNews = Server.CreateObject (\"ADODB.Recordset\")
strSQL = \"SELECT * FROM nyheder\"
rsNews.Open strSQL, Cn, adOpenKeySet, adLockOptimistic, adCmdTable
rsNews.Addnew
rsNews(\"overskrift\") = Request.form(\"overskrift\")
rsNews(\"nyhed\") = Request.Form(\"nyhed\")
rsNews(\"forfatter\") = Request.Form(\"forfatter\")
rsNews.Update
rsNews.Close
Set rsNews = Nothing
Cn.Close
set Cn = Nothing
Response.Redirect \"tilfojetNyhed.asp\"
%>
FÅR I FØRSTE OMGANG DENNE FEJLMEDD.:
Error Type:
ADODB.Recordset (0x800A0BB9)
Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
/Test/opretnyhed.asp, line 11