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

<!-- #include file="conn.asp" -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtdhttp://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>
<%
idd=request("id")
set rs=server.CreateObject("adodb.recordset")
rs.open "select * from product2 where idd='"&idd&"' order by idd desc",conn,1,1
rs.pagesize=3
page=1
if not isempty(Request.querystring("page")) then
page=csng(request.querystring("page"))
if page>rs.pagecount then
page=rs.pagecount
elseif page<1 then
page=1
end if
end if
if not rs.eof then
rs.AbsolutePage=cint(page)
end if
%>
<body>
<table width="293" border="1" align="center">
<tr>
<td width="83">&nbsp;</td>
<td width="85">&nbsp;</td>
<td width="103">&nbsp;</td>
</tr>
</table>
<% for i=1 to rs.pagesize %>
<table width="293" border="1" align="center">
<tr>
<td width="83"><%=rs("num")%></td>
<td width="85"><%=rs("name")%></td>
<td width="103"><%=rs("photo")%></td>
</tr>
</table>
<%
rs.movenext
next
%>
<a href="曹志平.asp?page=<%=page-1%>">上一页</a>
<a href="曹志平.asp?page=<%=page+1%>">下一页</a>
<%
rs.close
%>
</body>
</html>
错误类型:
ADODB.Field (0x80020009)
BOF 或 EOF 中有一个是“真”,或者当前的记录已被删除,所需的操作要求一个当前的记录。
/mingbo/曹志平.asp
如果我把
if not rs.eof then
rs.AbsolutePage=cint(page)
end if
该为
rs.AbsolutePage=cint(page)
提示参数类型不正确,或不在可以接受的范围之内,或与其他参数冲突。
/mingbo/曹志平.asp, 第 24 行
rs.AbsolutePage=cint(page)这就是24行

各位大哥大姐,我不知道错在那里,帮我看看错在那里

搜索更多相关主题的帖子: ASP 
2006-04-04 16:35
google
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:22
帖 子:3419
专家分:23
注 册:2005-11-1
收藏
得分:0 
if not (rs.eof and rs.bof) then
这样测试一下

祝天下所有母亲幸福安康!~
2006-04-04 16:52
快速回复:[求助]这个ASP分页错在那里???
数据加载中...
 
   



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

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