Java开发网 Java开发网
注册 | 登录 | 帮助 | 搜索 | 排行榜 | 发帖统计  

您没有登录

» Java开发网 » Java程序分享区  

按打印兼容模式打印这个话题 打印话题    把这个话题寄给朋友 寄给朋友    该主题的所有更新都将Email到你的邮箱 订阅主题
reply to topicflat modethreaded modego to previous topicgo to next topicgo to back
作者 熟悉ibatis的请帮帮忙!!!!
freetan





发贴: 2
于 2004-08-08 14:26 user profilesend a private message to userreply to postsearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
I use the executeQueryForPaginatedList() which returns a PaginatedList that retrieves records from the database at a time for display on a JSP. some code as follows:
PaginatedList pagelist=myservice.getFactitem();<%String pagedirection=servlet.requestStr(request,"pageDirection");if (pagedirection.equals("previous")) {pagelist.previousPage();}else if (pagedirection.equals("next")) { pagelist.nextPage();} %>

......
......//read and displayed data
......
<table align="center"><tr ><td colspan="5" align="right" valign="middle" class=link04>total<font color=red><%= myservice.getFactitemnum() %></font>records <% if (pagelist.isPreviousPageAvailable()) { %><a href="index.jsp?pageDirection=previous"><img src="/images/prev.gif" border="0"></a><% } if (pagelist.isNextPageAvailable()) { %><a href="index.jsp?pageDirection=next"><img src="/images/next.gif" border="0"></a><% } %> </td></tr></table>

------CASE----
when I have ONLY 2 page of records(20 rows), clicked on the "next page" button, row 11~20 were displayed. then clicked on "previous page" button,row 1~10 were displayed. when I have MORE THAN 2 page of records clicked on the "next page" button, row 21~30 were not displayed. the "next page" button do not work! what's wrong with my code? please help me!

Thanks...





reply to topicflat modethreaded modego to previous topicgo to next topicgo to back
  已读帖子
  新的帖子
  被删除的帖子
Jump to the top of page

   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923