求助,没有出错信息,不能在数据库里加入记录,急
下边这个是addcopier.asp文件
<% set cn= Server.CreateObject("adodb.connection") cn.open "DBQ="+server.mappath("./Copier.mdb")+";DRIVER={Microsoft Access Driver (*.mdb)};" set rst= Server.CreateObject("adodb.recordset") %> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <title>增加复印项目</title> </head> <body> <% strtype=Trim(request.Form("strtype")) gradation=trim(request.Form("gradation")) maxram=trim(request.Form("maxram")) Ram=trim(request.Form("Ram")) yutime=trim(request.Form("yutime")) power=trim(request.Form("power")) weight=trim(request.Form("weight")) standardpager=trim(request.Form("standardpager")) maxpager=trim(request.Form("maxpager")) speed=trim(request.Form("speed")) firsttime=trim(request.Form("firsttime")) fenbianl=trim(request.Form("fenbianl")) mulpower=trim(request.Form("mulpower")) maxpage=trim(request.Form("maxpage")) printspeed=trim(request.Form("printspeed")) printram=trim(request.Form("printram")) printinf=trim(request.Form("printinf")) printscript=trim(request.Form("printscript")) plate=trim(request.Form("plate")) if gradation=""then gradation="/" end if if standardpager=""then standardpager="/" end if if maxpager=""then maxpager="/" end if if speed=""then speed="/" end if if maxpage=""then maxpage="/" end if if printspeed=""then printspeed="/" end if if printram=""then printram="/" end if if printinf=""then printinf="/" end if if printscript=""then printscript="/" end if if plate<>"" and strtype<>"" and ram<>"" and maxram<>"" and yutime<>"" and power<>"" and weight<>"" and firsttime<>"" and fenbianl<>"" and mulpower<>"" then values="'"&plate&"','"&strtype&"','"&ram&"','"&maxram&"','"&yutime&"','"&power&"','"&weight&"','"&firsttime&"','"&fenbianl&"','"&mulpower&"'" values=values&gradation&"','"&standardpager&"','"&maxpager&"','"&speed&"','"&maxpage&"','"&printspeed&"','"&printram&"','"&printinf&"','"&printscript&"'" sqlstr="insert into copier values('"&plate&"','"&strtype&"','"&ram&"','"&maxram&"','"&yutime&"','"&power&"','"&weight&"','"&firsttime&"','"&fenbianl&"','"&mulpower&"','"&gradation&"','"&standardpager&"','"&maxpager&"','"&speed&"','"&maxpage&"','"&printspeed&"','"&printram&"','"&printinf&"','"&printscript&")" rst.open sqlstr,cn Response.Write("增加成功") cn.close else response.Redirect("addcopier.htm") end if %> </body> </html> 下边这个是addcopier.htm文件内容 <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <title>复印标配</title> <style type="text/css"> <!-- .style1 { font-size: 18px; font-weight: bold; } .style2 { font-size: 36px; font-weight: bold; color: #0000FF; } --> </style> </head> <body> <div align="center"><span class="style2">复印标配</span> </div> <center> <form name="form" method="post" action="addCopier.asp"> <p><span class="style1">复印规格</span></p> <p>类型: <input name="strtype" type="text" id="strtype" size="20"> 预热时间:小于 <input name="yutime" type="text" id="yutime" size="12"> 秒 </p> 内存: <input name="Ram" type="text" id="Ram" size="19"> M 标配容量: <input name="standardpager" type="text" id="standardpager" size="18"> 张 <p> 功率: <input name="power" type="text" id="power" size="19"> KW 最大容量: <input name="maxpager" type="text" id="maxpager" size="18"> 张</p> <p> 灰度: <input name="gradation" type="text" id="gradation" size="19"> 复印速度: <input name="speed" type="text" id="speed" size="15"> 张/分 </p> <p> 重量: <input name="weight" type="text" id="weight" size="16"> KG 连续复印: <input name="maxpage" type="text" id="maxpage" size="18"> 张 </p> <p>倍率: <input name="mulpower" type="text" id="mulpower" size="20"> 分辨率: <input name="fenbianl" type="text" id="fenbianl" size="20"> </p> <p>首张时间:小于 <input name="firsttime" type="text" id="firsttime" size="12"> 秒 最大内存: <input name="maxpage" type="text" id="maxpage" size="17"> M </p> <p class="style1">打印规格</p> <p>内存: <input name="printram" type="text" id="printram" size="20"> 打印速度: <input name="printspeed" type="text" id="printspeed" size="15"> 张/分</p> <p>接口: <input name="printinf" type="text" id="printinf" size="20"> 打印语言: <input name="printscript" type="text" id="printscript" size="20"> </p> <p><span class="style1">传真规格</span></p> <p>厂家: <input name="plate" type="text" id="plate"> </p> <p> <input type="submit" name="Submit" value="提交"> <input type="reset" name="Submit2" value="重置"> </p> </form> </center> </body> </html>