In Excel
Dim arr1 As Variant
arr1 = WorksheetFunction.Index(Cells, Evaluate("row(1:100)"), Array(1, 7, 4, 3, 2))
arr1 = Application.Index(Cells, Evaluate("row(1:100)"), Array(1, 7, 4, 3, 2))
The first attempt to assign a value to arr1 fails with an error 13 (Type Mismatch), but the second attempt works fine.
However, while the WorksheetFunction object is part of the Application object, the Application object itself appears to have no "index" method. Yet the code works. Any ideas why?
For what it's worth,
arr1 = Application.WorksheetFunction.Index(Cells, Evaluate("row(1:100)"), Array(1, 7, 4, 3, 2))
fails with an error 13 as well.