代码错误?求助!
这段代码那有问题?<%
set rs=server.CreateObject("ADODB.RECORDSET")
sql="select * from film where typeid='"&typeid&"' order by time desc" rs.open sql,conn,1,3
if rs.eof and rs.bof then
response.Write("当前还没有内容...")
else
dim currentpage
maxperpage=Sitebooknum
rs.pagesize=8
currentpage=request.querystring("pageid")
if currentpage="" then
currentpage=1
elseif currentpage<1 then
currentpage=1
else
currentpage=clng(currentpage)
if currentpage > rs.pagecount then
currentpage=rs.pagecount
end if
end if
if not isnumeric(currentpage) then
currentpage=1
end if
dim totalput,n
totalput=rs.recordcount
if totalput mod maxperpage=0 then (错误在这句: 错误类型:
Microsoft VBScript 运行时错误 (0x800A000B)
被零除
/list.asp, 第 354 行
)
n=totalput\maxperpage
else
n=totalput\maxperpage+1
end if
if n=0 then
n=1
end if
rs.move(currentpage-1)*maxperpage
i=0
w=1
do while i< maxperpage and not rs.eof
%>