Displaying Source Code(s)
|
|
RevArray Function - Reverse the order of an array
--------------------------------------------------------------------------------
Description : The RevArray function reverses the order of an
array. In other words, the upperbound value of an input array
will become the lowerbound value and all other values will
re-order themselves accordingly. RevArray returns an array.
<%
Private Function RevArray(ByVal arrayinput)
Dim i, ubnd
Dim newarray()
ubnd = UBound( arrayinput )
ReDim newarray(ubnd)
For i = 0 To UBound( arrayinput )
newarray( ubnd - i ) = arrayinput( i )
Next
RevArray = newarray
End Function
% |
|
|