中国联通交话费送会员:if rs.eof then
来源:百度文库 编辑:高校问答 时间:2024/03/29 17:57:51
<%
dim conn,rs,sql,i,connstr
connstr="provider=microsoft.jet.oledb.4.0; data source="&server.MapPath("bookshop.mdb")
set conn=server.CreateObject("adodb.connection")
conn.open connstr
set rs=server.CreateObject("adodb.recordset")
sql="select id,bookname from book order by total"
rs.open sql,conn,1,1
%>
<html>
<head>
<title>销量排行榜</title>
<meta http-equiv="content-type"content="text/html;charset=gb2312">
</head>
<body bgcolor="#ffffff"text="#000000">
<table width="100%"border="0">
<tr bgcolor="#ffffff">
<td colspan="2"><font size="2" color="#ffffff"><img src="gif/ph.gif" width="170" height="25"></img></font></td>
</tr>
<%
rd.pagesize=10
for i=1 to rs.PageSize
if rs.eof then
end if
%>
<tr>
<td width="13%">
<div align="><font size="2"><%=i%></font></div></td>
<td width="87%"><a href="detail.asp?id=<%=rs("id")%>"target="blank"><font size="2"><%=rs("bookname")%></font></a></td>
</tr>
<%
rs.movenext
next
%>
</table>
</body>
</html>
个位大吓看一看到底哪里错了
dim conn,rs,sql,i,connstr
connstr="provider=microsoft.jet.oledb.4.0; data source="&server.MapPath("bookshop.mdb")
set conn=server.CreateObject("adodb.connection")
conn.open connstr
set rs=server.CreateObject("adodb.recordset")
sql="select id,bookname from book order by total"
rs.open sql,conn,1,1
%>
<html>
<head>
<title>销量排行榜</title>
<meta http-equiv="content-type"content="text/html;charset=gb2312">
</head>
<body bgcolor="#ffffff"text="#000000">
<table width="100%"border="0">
<tr bgcolor="#ffffff">
<td colspan="2"><font size="2" color="#ffffff"><img src="gif/ph.gif" width="170" height="25"></img></font></td>
</tr>
<%
rd.pagesize=10
for i=1 to rs.PageSize
if rs.eof then
end if
%>
<tr>
<td width="13%">
<div align="><font size="2"><%=i%></font></div></td>
<td width="87%"><a href="detail.asp?id=<%=rs("id")%>"target="blank"><font size="2"><%=rs("bookname")%></font></a></td>
</tr>
<%
rs.movenext
next
%>
</table>
</body>
</html>
个位大吓看一看到底哪里错了
应该把 if rs.eof then end if 改成 while not (rs.eof and rs.bof)
再写你的读取数据库的代码, 再才是 rs.movenext wend 参考ASP语言
while(untile).....wend 语句
if rs.eof then 后面怎么紧接着就是 end if?
if rs.eof then
if rs.EOF and rs.BOF then
ASP代码:if rs.eof and rs.bof then
if not(rs.eof or rs.bof) then...
if rs.eof then | ASP代码什么意思?
if not rs.eof then什么意思啊?
n=0 for m=1 to rs.PageSize if rs.EoF then exit for
if not rshyk.eof then
if rsMenu.bof and rsMenu.eof then [大哥帮我理解一下意思]
if rs.recordcount<>"0" then 怎么解释呢