Skip to main content

VBA Array declared as constant?

 From excel - Can an array be declared as a constant? - Stack Overflow

You could use a function to return the array and use the function as an array.

Function ConstantArray()
    ConstantArray = Array(2, 13, 17)
End Function

Immediate window:
?ConstantArray(1)
13
?ConstantArray()(1)
13
?Join(ConstantArray,'','')
2,13,17


Comments

Popular posts from this blog

Add GitHub Repository to DBeaver CE Secured with SSH Protocol

Keyboard Shortcut to "Toggle Line Comments" in DBeaver

DBeaver Shortcuts