@jeminar has the best solution above.
I cleaned it up a bit though.
I recommend adding this to a FunctionsArray module
isInitialised=false
is not needed because Booleans are false when createdOn Error GoTo 0
wrap and indent code inside error blocks similar to with
blocks for visibility. these methods should be avoided as much as possible but ... VBA ...Function isInitialised(ByRef a() As Variant) As Boolean
On Error Resume Next
isInitialised = IsNumeric(UBound(a))
On Error GoTo 0
End Function