Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Order a string (asc)

Status
Not open for further replies.

BigBadDave

Programmer
May 31, 2001
1,069
EU
How can I order a string ascending.

This is what i've got :

<%
string = Split(Trim(Request.Querystring(&quot;string&quot;)), &quot;|&quot;)
%>

now I need to order it

any ideas?? Regards

Big Bad Dave

davidbyng@hotmail.com
 
Its ok I figured it out using server side JScript in conjunction with VBScript:

<script language=&quot;JScript&quot; type=&quot;text/JScript&quot; runat=&quot;server&quot;>
function SortVBArray(arrVBArray) {
return arrVBArray.toArray().sort().join('|');
}
</script>
<%
checkString = Split(SortVBArray(Request(string)), &quot;|&quot;)
For x=0 To uBound(checkString)
Response.Write checkString(x)
Next
%> Regards

Big Bad Dave

davidbyng@hotmail.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top