How to clear the Sort Properties?
We can clear the "Sort" properties.
The ASP codes are written and described as below:
<%
Set conn = Server.CreateObject("Adodb.Connection")
conn.Open "Driver={Microsoft Access Driver (*.mdb)};DBQ=" & Server.MapPath("db1.mdb")
Set rs = Server.CreateObject("Adodb.Recordset")
rs.CursorLocation = 3 'Set the CursorLocation = adUseClient
rs.Open "Member",conn,1,3
%>
<%
rs.Sort = "Location ASC" 'Sorting the Location fields in Ascending
If rs.EOF Then 'If Eof is True; that means is not record
%>
<%
Else
Do while Not rs.eof
%>
<%
rs.movenext
Loop
End If
%>
No member... | |||
<%=rs("MemID")%> | <%=rs("MemberName")%> | <%=rs("Location")%> |
<%
rs.Sort = "" 'Now we clear the Sort setup
If rs.EOF Then
%>
<%
Else
Do while Not rs.eof
%>
<%
rs.movenext
Loop
End If
rs.Close
Set rs = Nothing
%>
No member... | |||
<%=rs("MemID")%> | <%=rs("MemberName")%> | <%=rs("Location")%> |
No comments:
Post a Comment