ASP specifies to read the first few records

Source: Internet
Author: User

<%dim Sqlnote2


sqlnote2= "SELECT Top 8 * out note1 ORDER BY id DESC"


call OPENDB ()


Rs.Open sqlnote2,conn,1,1


if not rs.eof then


do, not rs.eof


    


%>


<tr>


<TD width= "5" height= "align=" "left" bgcolor= "#FFFFFF" > </td>


<td width= "169" height= "align=" "left" bgcolor= "#FFFFFF" ><img Src= "Index_files/dot_email.gif" width= "5" height= "5"/> <a href= "<%=rs (" File_path ")%>" target= " "_blank" class= "prodcut" title= "<%=rs (" title ")%>" ><%=rs "(" title ")%></a>  


<% if RS ("Send_date") =date () then


Response.Write ("<img src=index_files/new1.gif/>")


Else Response.Write (rs ("Send_date"))


End If%></td>


<td width= "1" height= "5" align= "left" bgcolor= "#FFFFFF" >  </td>


</tr>


<%


Rs.movenext


loop%>


<tr >


<TD colspan= "3" align= "right" bgcolor= "#FFFFFF" ><a href= "note.asp Tutorial" class= "page" > More information ...</a>    </td>


</tr>


<%


Else


%>


<tr class= "Button3" >


<td colspan= "3" bgcolor= "#FFFFFF" > No notification Notice </td>


</tr>


<%


End If


call Closedb ()


%>


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.