Archive of Mr Excel Message Board

Back to Printing in Excel archive index
Back to archive home

Multiple Sheet Printing ... HELP
Posted by Robert on April 03, 2000 4:32 PM
I've got a workbook with 182 sheets, all formatted exactly the same. I want to set the print area to print cells A1 thru Z50 on each of the 182 sheets. Unfortuately, I can find no simple way to do this. If I select all sheets, it does so, but all the page breaks are out of whack. I can manually reset the page breaks, but I'd rather not do that 182 times. Any assistance would be greatly appreciated.
Thank you.

Re: Multiple Sheet Printing ... HELP
Posted by Ivan Moala on April 03, 2000 11:24 PM
Robert
If you are familiar with macros
then the following should do what you want.
Sub Pagesetup()
Dim Sh
Dim Rg As String
Rg = "A1:Z50"
For Each Sh In ThisWorkbook.Sheets
Sh.Pagesetup.PrintArea = Rg
Next
End Sub
Ivan

This archive is from the original message board at www.MrExcel.com.
All contents © 1998-2004 MrExcel.com.
Visit our
online store to buy searchable CD's with thousands of VBA and Excel answers.
Microsoft Excel is a registered trademark of the Microsoft Corporation.
MrExcel is a registered trademark of Tickling Keys, Inc.