<%
Dim Nick,Name,Password,Email
Dim Province,City,Address,Zip,Phon
Nick=Trim(Request.Form("Nick"))
Name=Trim(Request.Form("Name"))
Password=Trim(Request.Form("Password"))
rePass=Trim(Request.Form("rePass"))
Email=Trim(Request.Form("Email"))
Province=Trim(Request.Form("Province"))
City=Trim(Request.Form("City"))
Address=Trim(Request.Form("Address"))
Zip=Trim(Request.Form("Zip"))
Phon=Trim(Request.Form("Phon"))
If Nick="" OR Name="" OR Password="" OR rePass="" OR Email="" OR Phon="" Then
ShowMessage "有必填项目没有填写!"
Set Conn=Nothing
Else
IF Password<>rePass then
ShowMessage "两次输入的密码不一样!"
set conn=nothing
end if
Set Conn = Server.CreateObject("ADODB.connection")
DB = "db1.mdb"
ConnStr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath(DB)
Conn.Open ConnStr
set rs=Server.CreateObject("ADODB.Recordset")
sql="Select *From Users Where Nick="&Nick&""
rs.open sql,conn,0,1
if rs.eof and rs.bof then
sql="insert into Users (Nick,Password,Name,Email,Province,City,Address,Zip,Phon)Values
('"&Nick&"','"&Password&"','"&Name&"','"&Email&"','"&Province&"','"&City&"','"&Address&"','"&Zip&"','"&Phon&"')"
Conn.execute sql
rs.close
set rs=nothing
set conn=nothing
response.write"<center>祝贺你注册成功!"&"按<a href=Welcome.asp>这里</a>进入欢迎页面</center>"
else
rs.close
set rs=Nothing
set conn=nothing
ShowMessage "此登录名已被注册!"
end if
end if
%>
<!--显示返回重新填写信息的Sub过程:-->
<%Sub ShowMessage(msg)%>
<body bgcolor="#ccffff">
<center>
<h3><%=msg%></h3>
</center>
<form>
<p align="center">
<input type=Button Value="返回重新填写" OnClick="history.back();">
</p>
</form>
</body>
<% Response.End %>
<% End Sub%>
<a href="index.asp" target="_self">注册成功,现登陆系统</a>!
<%
%>
</body>
</html>
Microsoft JET Database Engine 错误 '80040e10'
至少一个参数没有被指定值。
/登陆和注册/checkregi.asp,行 29
请大哥们帮忙看看
[此贴子已经被作者于2007-10-26 1:06:23编辑过]