关于asp的一点小问题?请教!

来源:百度知道 编辑:UC知道 时间:2024/05/04 04:02:42
我想在下面这条语句所定义的消息框中把要显示的消息加上循环效果<table width="100%" height="30" border="0" cellpadding="1" cellspacing="1">
<%sql="select Top 5 * from Xy_Gt where GtFLag=1 and GtNew=1 order by GtDate Desc"
rs.open sql,conn,1,1
if rs.recordcount=0 then
response.write" 暂时还没有信息..."
else
while not rs.eof
%>
<tr>
<td height="25" class="Table4"><a href="DongInfo.asp?Id=<%=rs("GtId")%>#"><%=left(rs("GtName"),12)% >...</a></td>
</tr>
<%
rs.movenext
wend
end if
rs.close%>
我是这样做的加了2条语句在<%=left(rs("GtName"),12)%>... 上如下面:
<marquee scrollamount=1 scrolldelay=45 direction=up id=info onmouseover=info.stop() onmouseout=info.start()>
<%=left(r

你应该滚动整个代码
可以写成这样
<marquee scrollamount=1 scrolldelay=45 direction=up id=info onmouseover=info.stop() onmouseout=info.start()>
<table width="100%" height="30" border="0" cellpadding="1" cellspacing="1">
<%sql="select Top 5 * from Xy_Gt where GtFLag=1 and GtNew=1 order by GtDate Desc"
rs.open sql,conn,1,1
if rs.recordcount=0 then
response.write" 暂时还没有信息..."
else
while not rs.eof
%>
<tr>
<td height="25" class="Table4"><a href="DongInfo.asp?Id=<%=rs("GtId")%>#"><%=left(rs("GtName"),12)% >...</a></td>
</tr>
<%
rs.movenext
wend
end if
rs.close%></table>
</marquee>

这样就可以滚动所有的了

你应该把下面的: