asp代码错误求助
小弟刚学写ASP,以下这段代码一直找不到错误,还请各位大师指教,由于本人刚学,还请讲的越详细越好.如果回答能解决小弟问题,加分不是问题.
代码如下::<%
dim sql,myErrors
if not isnumeric(request.querystring("id")) or isempty(request.querystring("id")) then msgboxU "非法参数!"
else
sql="delete from tbl_user where u_id="&request.querystring("id")
conn.execute sql
set myErrors=conn.errors
if myErrors.count=0 then
msgboxU "删除成功!"
else
msgboxU "删除失败!原因:"&myErrors.item(0).
description
end if
end if
conn.close
set conn=nothing
%>
浏览器显示代码:'Microsoft VBScript 编译器错误 (0x800A03EA) 语法错误5
------解决方案--------------------格式不对
<%
dim sql,myErrors
if not isnumeric(request.querystring("id")) or isempty(request.querystring("id")) then
msgboxU "非法参数!"
else
sql = "delete from tbl_user where u_id=" & request.querystring("id")
conn.execute sql
set myErrors = conn.errors
if myErrors.count = 0 then
msgboxU "删除成功!"
else
msgboxU "删除失败!原因:" & myErrors.item(0).description
end if
end if
conn.close
set conn = nothing
%>