首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 服务器 > 其他服务器 >

Provider '80020005',该怎么解决

2012-02-09 
Provider 80020005Provider 80020005类型不匹配。\admin\add_products.asp, line 167!--#include file

Provider '80020005'
Provider '80020005' 

类型不匹配。 

\admin\add_products.asp, line 167


<!--#include file="../inc/Conn.asp" -->
<!--#include file="seeion.asp"-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<link rel="stylesheet" type="text/css" id="css" href="images/style.css">
<title>增加产品</title>
<script language="javascript">
function showUploadDialog(s_Type, s_Link, s_Thumbnail){
var arr = showModalDialog("YFeWebEditor/dialog/i_upload.htm?style=popup&type="+s_Type+"&link="+s_Link+"&thumbnail="+s_Thumbnail, window, "dialogWidth:0px;dialogHeight:0px;help:no;scroll:no;status:no");}
</script>
<script language = "JavaScript">
<%
Set Rs= Server.CreateObject("Adodb.Recordset")
Rs.Open "SELECT * FROM SmallClass ORDER BY SmallClassID asc",conn,1,1
%>
var onecount;
onecount=0;
subcat = new Array();
<%
  i = 0
  Do While Not Rs.eof 
%>
subcat[<%=i%>] = new Array("<%= Trim(Rs("SmallClassName"))%>","<%= Rs("BigClassID")%>","<%= Rs("SmallClassID")%>");
<%
  i = i + 1
  Rs.MoveNext
  Loop
  Rs.Close
%>
  
onecount=<%=i%>;

function changelocation(locationid,formname)
  {
  formname.SmallClassID.length = 0; 

  var locationid = locationid;
  var i;
  for (i = 0;i < onecount; i++)
  {
  if (subcat[i][1] == locationid)
  {
  formname.SmallClassID.options[formname.SmallClassID.length] = new Option(subcat[i][0], subcat[i][2]);
  }  
  }
   
  }  
</script>
</head>
<body>
<form name="form1" method="post" action="add_products.asp?action=add">
<table width="95%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#666666">
  <tr>
  <td height="30" background="images/bg_list.gif"><div style="padding-left:10px; font-weight:bold; color:#FFFFFF">增加产品</div></td>
  </tr>
  <tr>
  <td bgcolor="#FFFFFF"><table width="100%" border="0" align="center" cellpadding="5" cellspacing="0" >
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#F1F5F8'" bgcolor="#F1F5F8" >
  <td height="28" width="16%" class="td">产品标题 <font color="#FF0000">*</font></td>
  <td width="84%" class="td">
  <input name="title" type="text" size="40" />
  <label>排序ID:
  <input name="px_id" type="text" id="px_id" value="1000" size="10" onkeyup="value=value.replace(/[^\d]/g,'') "onbeforepaste="clipboardData.setData('text',clipboardData.getData('text').replace(/[^\d]/g,''))" />


数值越小,排列越靠前</label></td>
  </tr>
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#FFFFFF'" bgcolor="#FFFFFF">
  <td width="16%" height="13" class="td">产品分类</td>
  <td class="td"><select name="BigClassID" id="BigClassID" onchange="changelocation(document.form1.BigClassID.options[document.form1.BigClassID.selectedIndex].value,document.form1)">
  <option value="">请选择大类</option>
  <%
 i = 0
 Set RsBig = Conn.Execute("SELECT * FROM BigClass ORDER BY px_id")
 Do While Not RsBig.Eof
  If i = 0 Then BigClassID = RsBig(0)
  Response.Write("<option value="""&RsBig(0)&""">"&RsBig(1)&"</option>")
  i = i + 1
  RsBig.MoveNext
 Loop
 Set RsBig = Nothing
 %>
  </select>
  <select name="SmallClassID" id="SmallClassID">
<option value="">请选择小类</option>
 <%
 If BigClassID <> "" Then
  Set RsSmall = Conn.Execute("SELECT * FROM SmallClass WHERE BigClassID = "&BigClassID)
  Do While Not RsSmall.Eof
  Response.Write("<option value="""&RsSmall(0)&""">"&RsSmall(1)&"</option>")
  RsSmall.MoveNext
  Loop
 End if
 Set RsSmall = Nothing
 %>
 </select></td>
  </tr>
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#F1F5F8'" bgcolor="#F1F5F8">
  <td height="13" class="td">发布作者</td>
  <td class="td"><% 
exec="select * from admin where id="&session("admin")&" "
set rsn=server.createobject("adodb.recordset") 
rsn.open exec,conn,1,1 
%> <input name="zz" type="text" value="admin" size="30" /></td>
  </tr>
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#FFFFFF'" bgcolor="#FFFFFF">
  <td height="25" class="td">产品略缩图</td>
  <td class="td"><input name=img type=text value="/images/noimages.gif" size=50> <input type=button value="上传图片" onClick="showUploadDialog('image', 'form1.img', '')" class="btn"></td>
  </tr>
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#F1F5F8'" bgcolor="#F1F5F8">
  <td height="25" class="td">产品价格</td>
  <td class="td"><label>
  <input name="jiage" type="text" value="0" size="20" /> 
  ¥
  </label></td>
  </tr>
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#FFFFFF'" bgcolor="#FFFFFF">
  <td height="25" class="td">产品介绍 <font color="#FF0000">*</font></td>
  <td class="td"><INPUT type="hidden" name="body" value="">


  <iframe id="eWebEditor1" src="YFeWebEditor/ewebeditor.htm?id=body&style=popup" frameborder="0" scrolling="no" width="600" height="350"></iframe></td>
  </tr>
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#F1F5F8'" bgcolor="#F1F5F8">
  <td height="13" class="td">是否推荐</td>
  <td class="td"><label>
  <input name="tuijian" type="radio" value="0" checked="checked" />不推荐
  <input type="radio" name="tuijian" value="1" />推荐 </label></td>
  </tr>
  <tr onmouseover="style.backgroundColor='#EEEEEE'" onmouseout="style.backgroundColor='#F1F5F8'" bgcolor="#F1F5F8">
  <td height="12" class="td">&nbsp;</td>
  <td class="td"><input type="submit" name="button" id="button" value="确认提交" class="btn"/></td>
  </tr>
  </table>
</td>
  </tr>
</table></form>
</body>
</html>
<%
if request("action")="add" then
set rs=server.createobject("adodb.recordset")
sql="select * from products"
rs.open sql,conn,1,3
title=request.form("title")
body=request.form("body")
img=request.form("img")
zz=request.form("zz")
BigClassID=request.form("BigClassID")
SmallClassID=request.form("SmallClassID")
hit=request.form("hit")
jiage=request.form("jiage")
tuijian=request.form("tuijian")
px_id=request.form("px_id")
if title="" then 
response.Write("<script language=javascript>alert('产品标题不能为空!');history.go(-1)</script>") 
response.end 
end if
if body="" then 
response.Write("<script language=javascript>alert('产品内容不能为空!');history.go(-1)</script>") 
response.end 
end if
rs.addnew
rs("title")=title
rs("body")=body
rs("img")=img
rs("zz")=zz
rs("BigClassID")=BigClassID
rs("SmallClassID")=SmallClassID
rs("hit")=hit
rs("jiage")=jiage
rs("tuijian")=tuijian
rs("px_id")=px_id
rs.update
rs.close
set rs=nothing
conn.close
set rs=nothing
Response.Write "<script>alert('产品增加成功,点击继续增加!');window.location.href='admin_products.asp';</script>" 
end if 
%>

[解决办法]

热点排行