| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 442 人关注过本帖
标题:[求助] 这段程序那里错拉?
只看楼主 加入收藏
aimama
Rank: 1
等 级:新手上路
帖 子:41
专家分:0
注 册:2007-6-19
收藏
 问题点数:0 回复次数:4 
[求助] 这段程序那里错拉?

问题:错误类型:
ADODB.Recordset (0x800A0BB9)
参数类型不正确,或不在可以接受的范围之内,或与其他参数冲突。
/sbiao/product.asp, 第 104 行

<%
one=request("one")
two=request("two")
three=request("three")
four=request("four")
news=request("news")
if one="" and two="" and three="" and four="" then
sql="select * from [product] where news=true order by order1 asc"
elseif one<>"" and two="" and three="" and four="" then
sql="select * from [product] where one="&one&" and news=true order by order1 asc"
elseif one<>"" and two<>"" and three="" and four="" then
sql="select * from [product] where one="&one&" and two="&two&" and news=true order by order1 asc"
elseif one<>"" and two<>"" and three<>"" and four="" then
sql="select * from [product] where one="&one&" and two="&two&" and three="&three&" and news=true order by order1 asc"
else
sql="select * from [product] where one="&one&" and two="&two&" and three="&three&" and four="&four&" and news=true order by order1 asc"
end if
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
if not rs.eof=false then

response.write("<div align=center>暂时无记录!</div>")

else


ps=tr*td
rs.pagesize=ps  //第104行
trcount=tr
tdcount=td
page=clng(request("page"))
if page<1 or page="" then
page=1
end if
if page>rs.pagecount then
page=rs.pagecount
end if
rs.absolutepage=page
end if


%>
<table width="100%" border="0" align="center" id="table1">
<%for i=1 to trcount %>
<tr>
<% for j=1 to tdcount %>
<% if not rs.eof then %>
<td>
<TABLE cellSpacing=3 cellPadding=3 border=0 width="25%">
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=1 cellPadding=0 bgColor=#efe5dc
border=0>
<TBODY>
<TR>
<TD bgColor=#ffffff><a href="ProductShow.asp?id=<%=rs("id")%>&one=<%=rs("one")%>" title="<%=rs("title")%>"><img src="UploadFiles/<%=trim(rs("smallpic"))%>" width="<%=w%>" height="<%=h%>" border="0" align="middle" style="border-color:#cccccc;" onload=javascript:DrawImage(this);></a></TD></TR></TBODY></TABLE></TD></TR>
<TR>
<TD height=25 align="center"><a href="ProductShow.asp?id=<%=rs("id")%>&one=<%=rs("one")%>" title="<%=rs("title")%>" class=main01 ><%=left(rs("title"),8)%> </a></TD></TR></TBODY></TABLE>
</td>
<% rs.movenext

else
exit for
end if
next
%>
</tr>

<%
next
%>
</table>
<br></td>
</tr>
<tr>
<td height="1" colspan="3" bgcolor="#e1e1e1"></td>
</tr>
<tr>
<td>&nbsp;</td>
<td height="8" class="main01"><div align="center">

共有<%=rs.recordcount%>件产品&nbsp;&nbsp; 共有<%=rs.pagecount%>页&nbsp;&nbsp;
每页<%=ps%>条记录 目前在第<%=page%>页
<%
if rs.pagecount >1 then
response.Write("<table><tr><td>分页:</td>")
for i= 1 to rs.pagecount
response.Write("<td>[<A href='?one="&one&"&page="&i&"'>"&i&"</a>]</td>")
next
response.Write("</tr></table>")
end if
RS.close
set rs=nothing
%>


 请问那里错了????

搜索更多相关主题的帖子: request color where 
2007-06-23 16:39
zhulei1978
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:53
帖 子:1351
专家分:1200
注 册:2006-12-17
收藏
得分:0 
ps=tr*td
tr和td从哪里得到的

其实我就是改变社会风气,提高少女素质,刺激电影市道,提高年轻人内涵,玉树临风,风度翩翩的整蛊专家,我名叫古晶,英文名叫JingKoo!
2007-06-23 20:43
alxw4616
Rank: 1
等 级:新手上路
帖 子:12
专家分:0
注 册:2007-6-23
收藏
得分:0 
'tr td is null
ps = tr * td
if ps = "" then
ps = 1
else
ps = cint(ps)
end if

2007-06-23 22:48
恒天
Rank: 1
等 级:新手上路
威 望:2
帖 子:165
专家分:0
注 册:2007-6-1
收藏
得分:0 
首先你这个文件有没有包含连接文件?
请将全部这个文件全部内容发出来看看
2007-06-24 12:00
yms123
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:209
帖 子:12488
专家分:19042
注 册:2004-7-17
收藏
得分:0 

rs.pagesize必须是Integer型的。

2007-06-24 20:43
快速回复:[求助] 这段程序那里错拉?
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.014918 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved