#12005/10/25 8:53:00
<% Option Explicit %>
<% Response.Buffer=True %>
<html>
<head>
<title>新建网页 1</title>
</head>
<body>
<h2 align="center">修改网站</h2>
<%
dim varid
varid=request.querystring("id")
Dim conn
set conn=server.createobject("adodb.connection")
conn.open "provider=microsoft.jet.oledb.4.0;data source="&server.mappath("db1.mdb")
dim strsql,rs
strsql="select * from fing where id="&varid
set rs=conn.execute(strsql)
%>
<center>
<table border="1" width="80%">
<form action="" method="post" name="form1">
<tr>
<td>网站名字</td><td><input type="text" name="name" size="20" value="<%=rs("name")%>"></td>
</tr>
<tr>
<td>网站网址</td><td>
<input type="text" name="URL" size="20" value="<%=rs("URL")%>"></td>
</tr>
<tr>
<td>网站简介</td><td>
<textarea name="intro" rows="7" cols="60" wrap="soft"><%=rs("intro")%></textarea></td>
</tr>
<tr>
<td><input type="submit" value="确定"></td>
</tr>
</form>
</table>
</center>
<%
dim varname,varURL,varintro
if request("name")<>"" and request("URL")<>"" and request("intro")<>"" then
varname=Request("name")
varURL=Request("URL")
varintro=Request("intro")
strsql="update fing set name='"&varname&"',URL='"&varURL&"','intro="&varintro&"' where id="&varid
conn.createcommand(s)
conn.Execute()
response.redirect "0.asp"
else
response.write "请填完信息!!!"
end if
%>
</body>
</html>
请达人帮忙看看,为什么总是 UPDATE 错误呢?