« Previous Next »

Thread: Creating an ascending and descending option in an asp page

Last post 09-20-2006 4:15 PM by tomkmvp. 1 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (2 items)

Sort Posts:

  • 09-20-2006, 10:02 AM

    • lbradio
    • Not Ranked
    • Joined on 06-09-2006, 8:19 PM
    • Posts 5

    Creating an ascending and descending option in an asp page

    The next part of a script generates a directorylisting. I like to add the option ascending and descending sorting on each item (Naam, KB, Type, Datum and Tijd) by clicking on this item, but I am not sure how to do this. Are there any suggestions?

    =========

    <div align="center"><center>
    <table width="100%" border="0" cellspacing="1" cellpadding="2">
        <tr>
          <th align="left"><p class="kopblauw">Naam</p></th>
          <th align="right"><p class="kopblauw">KB</p></th>
          <th align="right"><p class="kopblauw">Type</p></th>
          <th align="right"><p class="kopblauw">Datum</p></th>
          <th align="right"><p class="kopblauw">Tijd</p></th>
        </tr>

    <%
       ''''''''''''''''''''''''''''''''''''''''
       ' output the folder list
       ''''''''''''''''''''''''''''''''''''''''

       Set objCollection = objFolder.SubFolders

       For Each objItem in objCollection

          strName = objItem.Name
          strAttr = MakeAttr(objItem.Attributes)     
          dtmDate = CDate(objItem.DateLastModified)

       if not ((Left(strName, 1) = "_") OR (Right(strName, 10) = "_bestanden")) then
    %>


    <tr>
       <td align="left"><b><a href="<%=strName%>"><%=strName%></a></b></td>
       <td align="right"><%=intSizeK%>K</td>
       <td align="right"><b>Directory</b></td>
       <td align="right"><%=FormatDateTime(dtmDate,vbShortDate)%></td>
       <td align="right"><%=FormatDateTime(dtmDate,vbLongTime)%></td>
    </tr>
    <%
    end if
    Next
    %>

    ======

  • 09-20-2006, 4:15 PM In reply to

    • tomkmvp
    • Top 10 Contributor
    • Joined on 03-20-2003, 6:27 AM
    • Central NJ
    • Posts 6,238
    • IIS MVPs

    Re: Creating an ascending and descending option in an asp page

Page 1 of 1 (2 items)
Microsoft Communities