Selecting worksheets without hardcoding
Can I activate more than one at a time though? What I want to do is for instance select CA,AZ and Branch 1 Summary at the same time, and then copy to a new workbook for distribution to branch 1. The code in the recorder looks like this
Sheets(Array("Branch 102 Totals", "AL", "FL", "GA", "MS", "102 Competition")).Cop
ChDir "V:\Branch and Corporate\BR102
ActiveWorkbook.SaveAs Filename:=
"V:\Branch and Corporate\BR102\Branch102BARModel.xls", FileFormat:=xlNormal,
Password:="", WriteResPassword:="", ReadOnlyRecommended:=False,
CreateBackup:=Fals
What I can't figure out is how to create the Sheets(Array) Function without hardcoding the names in there. Since we periodically re-assign states, I want Excel to be able to pick to right sheets to save to each branch based on a lookup table rather than editing the code every time
Thanks
Thanks
|