I want to write amacro to print out all sheets in a workbook that have a certain name. In this case all the sheets in question are copies of one another, example
"Sheet1 (2)", "sheet1 (3)", "sheet1 (4)" and so on. I can't figure out how to write a macro just to select those sheets and no others. Right now it just searches for Sheet1 (2) through sheet1 (100) skipping over any missing ones with an on error resume next statement. This works, but it seems like a waste of code space. Trying to replace the number in brackets with a wildcard and using a for next loop doesn't work.
"Sheet1 (2)", "sheet1 (3)", "sheet1 (4)" and so on. I can't figure out how to write a macro just to select those sheets and no others. Right now it just searches for Sheet1 (2) through sheet1 (100) skipping over any missing ones with an on error resume next statement. This works, but it seems like a waste of code space. Trying to replace the number in brackets with a wildcard and using a for next loop doesn't work.