I am trying to write some code that will create new worksheets based on the selection of certain controls on a userform, run some code on those newly created sheets and then print them. I have accomplished the first two goals. I am now on to printing. I want to print the newly created sheets at one time by adding them to an array first. There in lies my hangup. This is the first time I have ventured into using arrays.
I have the following code but keep getting an error that says "Compile Error: Expected Array":
The debugger only highlights
, not the nWs if that helps.
I thought the ReDim command creates the array so I'm a little baffled as to why there isn't an array where one is expected. Again, arrays are new to me.
I appreciate any help.
Thank you.
Bookmarks