分页问题
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%><%
dim conn
set conn = server.createobject("ADODB.connection")
conn.connectionstring="Provider = microsoft.ace.oledb.12.0;Data Source="&server.mappath("persondatabase.accdb")
conn.open
dim rs
set rs = server.createobject("ADODB.recordset")
rs.open "零件报价表",conn,1,1
%>
<html>
<head>
<title>分页技术</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<style>
*{ margin:0; padding:0; }
body { font-szie:12px; color:#CC9900; font-family:"Times New Roman", Times, serif; background-color:#99CC66; }
p { color:#000000; font-size:20px; }
H6 { font-size:20px; font-weight:normal; text-align:center; }
H6 a { padding:3px; text-decoration:none; color:#000000; }
H6 a:hover { text-decoration:none; color:#FFCC00; }
table { background-color:#99CC66; margin:10px auto; }
table tr { background-color:#FFFF99; text-align:center; }
table tr th { font-size:14px; color:#FF0000; padding:10px;}
table tr td { color:#CC9900; padding:10px;}
</style>
</head>
<body>
<%rs.pagesize=5%>
<p><%=rs.pagecount%></p>
<%rs.absolutepage=2%>
<p><%=rs.absolutepage%></p>
<H6><%
for i=1 to rs.pagecount '这句代码原来是 do while not rs.eof 下面对应的是loop,现在做分页,换成for 语句之后错误提示下面的for 无效,是怎么回事
response.write "<a href='database_8.asp?page="&i&"'>"&i&"</a>"&"|"
next
%></H6>
<table >
<tr>
<%
for i=0 to rs.fields.count-1
%>
<th><%=rs.fields(i).name%></th>
<%
next
%>
</tr>
<%
for i=0 to rs.pagesize
%>
<tr>
<%
for i=0 to rs.fields.count-1
%>
<td><%=rs.fields(i).value%></td>
<%
next
rs.movenext
%>
</tr>
<%
next
%>
</table>
</body>
</html>
<%
conn.close
set conn=nothing
%>