ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   printing multiple sheets (https://www.excelbanter.com/excel-discussion-misc-queries/206760-printing-multiple-sheets.html)

jase

printing multiple sheets
 
I need to print multiple sheets using VBA. I am currently using a looping
function to colate them that says

For intStart = 1 To intCopies
Sheets(1).Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets(2).Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Next intStart

Is their a faster way to do this?

thanks,

Jase

Jim Rech

printing multiple sheets
 
You can select all the sheets first and then print:

For Counter = 1 To 3
Worksheets(Counter).Select False
Next
ActiveWindow.SelectedSheets.PrintOut

Also, you can print an array of sheet names without selecting them:

Worksheets(Array("Sheet1", "Sheet2")).PrintOut


--
Jim
"Jase" wrote in message
...
|I need to print multiple sheets using VBA. I am currently using a looping
| function to colate them that says
|
| For intStart = 1 To intCopies
| Sheets(1).Select
| ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
| Sheets(2).Select
| ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
| Next intStart
|
| Is their a faster way to do this?
|
| thanks,
|
| Jase



All times are GMT +1. The time now is 08:44 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com