日期:2014-05-17  浏览次数:20889 次

請大家 幫忙. ... ... .... ..3Q
<%
  rs.PageSize=6
Page=Clng(Request( "PageText "))
if   Page <1   then   Page=1
if   Page> rs.PageCount   then   Page=rs.PageCount
rs.AbsolutePage   =   Page
ShowPage   rs,Page
%>

<div   align= "center ">
<form   action= "http://localhost/testasp/dfdsfsdfs.asp "   method= "get "   ID= "Form1 ">
<%
        if   Page   <>   1   then
    Response.Write " <a   href=http://localhost/testasp/dfdsfsdfs.asp?PageText=1> 第一頁 </a> "
      Response.Write " <a   href=http://localhost/testasp/dfdsfsdfs.asp?PageText= "&(Page-1)& "> 上一頁 </a> "
end   if
if   Page <> rs.PageCount   then
Response.Write " <a   href=http://localhost/testasp/dfdsfsdfs.asp?PageText= "&(Page+1)& "> 下一頁 </a> "
Response.Write " <a   href=http://localhost/testasp/dfdsfsdfs.asp?PageText= "&rs.PageCount& "> 最后一頁 </a> "
end   if
%>
<p> 輸入頁號: <input   type= "text "   name= "PageText "   size= "3 "   ID= "Text1 "> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;   總頁數: <font   color= "red "> <%=Page%>
/ <%=rs.PageCount%> </font> </p>

<%
Sub   ShowPage(rs,Page)
Response.Write " <Center> "
do   while   not   rs.EOF
t1=rs( "AA ")
t2=rs( "BB ")
t3=rs( "CC ")
t4=rs( "DD ")
tt= " <tr   align= 'center '> <td> "&t1& " </td> <td> "&t2& " </td> <td> "&t3& " </td> <td> "&t4& " </td> <td> "
tt=tt& " <a   href=Update.asp?id= "&t1& "> 修改 </a> <a   href=Delete.asp?id= "&t1& "> ||刪除 </a> </td> </tr> "
response.Write   tt
rs.MoveNext
loop
Response.Write " </Table> </center> "
end   sub
conn.Close
set   conn=nothing
%>
請問怎樣才能每個葉面的記錄顯示為6條.
搞的郁悶啊.請神指點.

------解决方案--------------------
dim i
i=0
do while not rs.EOF and i <=6
t1=rs( "AA ")
t2=rs( "BB ")
t3=rs( "CC ")
t4=rs( "DD ")
tt= " <tr align= 'center '> <td> "&t1& " </td> <td> "&t2& " </td> <td> "&t3& " </td> <td> "&t4& " </td> <td> "
tt=tt& " <a href=Update.asp?id= "&t1& "> 修改 </a> <a href=Delete.asp?id= "&t1& "> ||刪除 </a> </td> </tr> "
response.Write tt
rs.MoveNext
i=i+1
loop


定义个i就可以了