I have 23 separate EXCEL files–one for each principal. Each file contains three sheets–two with graphs that are printed to a Adobe pdf file and the third sheet contains the data elements for the graphs and is not printed. These work sheets are updated monthly and a new Adobe PDF file is created after the monthly update. I am very new to VBA. I had EXCEL create a macro from my keystrokes to print the two graph sheets [pages]. I select a print range, the print format [landscape], the printer and finally press ok to print. EXCEL has recorded my key stokes and the macro runs as intended. .
My question is that I would like to make this same print macro available in the 22 other files—but I don’t want to create something permanent in EXCEL that is always on the toolbar but only works with these 23 files. What is the most productive way to get the “recorded” print macro from my first file to other 22 files? Can you copy and paste macro code? I am afraid that the “recorded” macro references the current workbook and will not “run” if I merely paste it into the other 22 workbooks.
I was also hoping that I didn’t have to re-record the same keystokes for each of the other 22 files. THANKS.