Esteemed Forum Participants and Lurkers:
===============================
EXCEL VBA
How do I initialize a global array?
I can Dim an array before any of my Subs/Functions, but if I do that, there doesn't seem to be any way to initialize the array in the Dim statement.
I can set: VarName = Array(7, 3, 8, 4)
but I have to do that in a Sub/Function, and I need to get to the array from several different Subs/Functions. I don't really want to initialize the array every time I call a Sub/Function that uses it. And no, I don't want write a test to see if it is initialized. I just want to create and initialize the array one time.
Thank you for any and all comments, suggestions, and assistance.




Reply With Quote