如何在ASP页面中实现产品换页显示?

[复制链接]
查看11 | 回复1 | 2007-3-5 11:45:56 | 显示全部楼层 |阅读模式
用asp分页就行了!adodb.connetction几个参数PageSize--每一页所含记录数; PageCount--当前记录的总页数; AboslutePage--当前记录位置的绝对页数; RecordCount--当前记录集的总数; AbsolutePosition当前记录所在的绝对位置; BOF--指针是否在记录集的头处; EOF--指针是否在记录集的尾处; BookMark--设置和得到当前记录的唯一位置给你一个例子你看看:http://www.java-asp.net/software/0408/621427.shtml
回复

使用道具 举报

千问 | 2007-3-5 11:45:56 | 显示全部楼层
核心代码如下还没有任何记录!
" else totalPut=rs.recordcount totalPut=rs.recordcount if currentpagetotalput then if (totalPut mod MaxPerPage)=0 then currentpage= totalPut \ MaxPerPage else currentpage= totalPut \ MaxPerPage + 1 end if end if if currentPage=1 then showpages showContent showpages else if (currentPage-1)*MaxPerPage '在此调用你要的新闻,比如 =MaxPerPage then exit do rs.movenext loop end sub sub showpages() dim n if (totalPut mod MaxPerPage)=0 then n= totalPut \ MaxPerPage else n= totalPut \ MaxPerPage + 1 end if if n=1 then response.write "新闻界面"exit sub end if dim k response.write ">> 新闻分页 " for k=1 to n if k=currentPage then response.write "["+Cstr(k)+"] " else response.write "["+""+Cstr(k)+"] " end if next end sub %>
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行