First I’ve never dealt with arrays before. So there is that issue to start
I have a vba script that cycles through the data and create worksheet tabs as it processes. The tab names are variables that are different each time the script is ran.
Right now I am formatting / adding formulas to each sheet as the script runs. I would like to create all the tabs and then select the tabs as a group. Then make the tabs pretty as a set. This should be a time savings for the script.
I can record the code, but I cannot figure out how to define/redefine the array on the fly.
When I record I get this line:
Sheets(Array(“EXP20010501”, “EXP20010578”, “EXP20011029”)).Select
So how do I code the creation of the array on the fly I mean as I create each new tab, redefine the array to include that new tab. When the script is through creating the tabs, then I use the list of tab names to select all of the necessary tabs
Thanks Mike
I have a vba script that cycles through the data and create worksheet tabs as it processes. The tab names are variables that are different each time the script is ran.
Right now I am formatting / adding formulas to each sheet as the script runs. I would like to create all the tabs and then select the tabs as a group. Then make the tabs pretty as a set. This should be a time savings for the script.
I can record the code, but I cannot figure out how to define/redefine the array on the fly.
When I record I get this line:
Sheets(Array(“EXP20010501”, “EXP20010578”, “EXP20011029”)).Select
So how do I code the creation of the array on the fly I mean as I create each new tab, redefine the array to include that new tab. When the script is through creating the tabs, then I use the list of tab names to select all of the necessary tabs
Thanks Mike