Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22
Default Print area multiple sheets

Hello all.

I have a spreadsheet Excel 2003 with 20-40 sheets in it, this can vary.
What I would like to have happen

1. Set the print area on all sheets in the workbook
find the last row on all sheets, then set the print area there up to and
including column e
the data goes on to column w if that matters

Thanks

Ian


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default Print area multiple sheets

Try this

Sub missive()
Dim ws As Worksheet
For x = 1 To Worksheets.Count
LastRow = Worksheets(x).Cells.SpecialCells(xlLastCell).Row
Worksheets(x).PageSetup.PrintArea = "$A$1:$E$" & LastRow
Next
End Sub

Mike

"ian bartlett" wrote:

Hello all.

I have a spreadsheet Excel 2003 with 20-40 sheets in it, this can vary.
What I would like to have happen

1. Set the print area on all sheets in the workbook
find the last row on all sheets, then set the print area there up to and
including column e
the data goes on to column w if that matters

Thanks

Ian



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22
Default Print area multiple sheets

That works great !!

Thanks

Ian

"ian bartlett" wrote in message
news:9VJbk.58308$Jx.19622@pd7urf1no...
Hello all.

I have a spreadsheet Excel 2003 with 20-40 sheets in it, this can vary.
What I would like to have happen

1. Set the print area on all sheets in the workbook
find the last row on all sheets, then set the print area there up to
and including column e
the data goes on to column w if that matters

Thanks

Ian




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Print multiple Area and wrap together LP Excel Discussion (Misc queries) 1 February 17th 10 06:54 PM
MULTIPLE PRINT AREA Raz Excel Worksheet Functions 3 January 14th 10 09:47 PM
setting page setup/print area for multiple sheets [email protected] Excel Discussion (Misc queries) 6 October 27th 07 01:19 PM
Multiple print-area SteveDB1 Excel Programming 6 September 7th 07 12:56 AM
set the print area print multiple tabs veng Excel Discussion (Misc queries) 5 February 12th 05 07:01 PM


All times are GMT +1. The time now is 11:59 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"