Reverse Method
Reverses the order of the elements in the entire ArrayList
object.
Syntax
Object.Reverse()
Arguments - Object: Required. Always the name of
ArrayList
object.
Remarks
The following example illustrates the use of the Reverse method.
Example 1:
'Create ArrayList Object
Dim Obj
Set Obj = CreateObject("System.Collections.ArrayList")
'Add Elements to the end of ArrayList Object
Dim Index
Index = Obj.Add(10)
Index = Obj.Add(40)
Index = Obj.Add(20)
Index = Obj.Add(30)
'Reverses the order of the elements in the entire ArrayList Object
Obj.Reverse()
'Output: Obj contains 30, 20, 40, 10