老项目vb写的asp代码,陷入死循环,求大家帮看看
求助老项目vb写的asp代码,陷入死循环,求大家帮看看啊
------解决方案--------------------
do while not rsSmallClass.eof
在这句语句前面追加个rsSmallClass.MoveFirst试试?
或者看看rsSmallClass.RecordCount是不是0
sqlSmallClass="select * from SmallClass_new where BigClassID=3 order by smallclassid asc"
Set rsSmallClass= Server.CreateObject("ADODB.Recordset")
rsSmallClass.open sqlSmallClass,conn,1,1
if not rsSmallClass.eof then%>
<%do while not rsSmallClass.eof%>
<li><a href="news.asp?biguid=3&smauid=<%=rsSmallClass("smallclassid")%>"><%=rsSmallClass("smallclassname")%></a></li>
<%rsSmallClass.movenext
loop
rsSmallClass.close
set rsSmallClass=nothing
end if
------解决方案--------------------
do while not rsSmallClass.eof
在这句语句前面追加个rsSmallClass.MoveFirst试试?
或者看看rsSmallClass.RecordCount是不是0