不知道具体如何用,请明示。 程序如下
<%
SQL="select top 9 * from news Where bigclassname='前沿快讯' order by newsid desc"
Set Rs=Server.CreateObject("Adodb.Recordset")
'response.write sql
Rs.Open SQL,Conn,1,1
if not Rs.EOF then
for i=1 to rs.recordcount
if Rs.EOF then exit for
%><%d1=rs("updatetime")
d2=dade()
d3=dadediff("d",d1,d2)%>
· <A href="shownews.asp?newsid=<%=rs("newsid")%>" target=_blank>
<%if len(rs("title"))<=24 then%>
<%=rs("title")%>
<%else%>
<%=left(rs("title"),24)&"…"%>
<%end if%>
<span style="line-height: 150%; margin-top: 3; margin-bottom: 3">
<%=month(rs("updatetime"))&"-"&day(rs("updatetime"))%></span><%if d3>3 then
%><%=rs("title")%>news<%else%><%=rs("title")%><%end if%>
</A>
</span><br>
<%
Rs.MoveNext
next
end if
rs.close
set rs=nothing
%>
结果运行 类型不匹配: 'dade'