主题:  我要在哪加 END IF啊?帮我一下!

icerain

职务:普通成员
等级:1
金币:1.0
发贴:249
#12003/7/14 23:44:26
请注意代马中有错误原因!!!

<%
strConn = "driver={MicroSoft Access Driver (*.mdb)};dbq=" & Server.Mappath("mdb.mdb")
Set rs = Server.CreateObject("Adodb.Connection")
SQL1 = "SELECT * FROM game order by id desc"
rs.Open sql1,strconn,3,2

if not rs.eof then '--------------------1处!!!!!!!!!

Response.Write "对不起,数据库中暂时没有记录!"
else
rs.pagesize=20
pages=rs.pagesize
totalreords=rs.recordcount
totalpage=teotalrecords/pages

如果这里不加 END IF 则 1处错误 如果加则2处错误!

if (totalrecords mod pages) <>0 and (totalrecords / pages) > 1 then totalpage=totalpage+1
if (totalrecords/pages)<1 then totalpage=1
page=request.querystring("page")
if page="" then page=1

frs.absolutepage=page
i=0
do while not frs.eof
Response.Write"
"&rs("name")&""&rs("lei")&""&rs("cd")&""&rs("time")&"