LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Multiple print areas


The below piece of VB prints out a print area on my worksheet OK where
the print area varies in length.

Sub Button4_Click()
cc = 26
For r = 26 To 150
If Sheets("Moves Request Form").Range("AF" & r) = "CC Reference Number
:-" Then cc = r
Next r
Sheet1.PageSetup.PrintArea = "B3:CP" & cc 'Sets the Print area
ActiveSheet.PrintOut 'Prints the Print area
Sheet1.PageSetup.PrintArea = "" 'Clears the Print area
End Sub

There is always a piece of data in the middle somewhere that I dont
need to appear on the printout.
Is there any way I can include two different print areas in the above
VB?


--
grahammal
------------------------------------------------------------------------
grahammal's Profile: http://www.excelforum.com/member.php...o&userid=20336
View this thread: http://www.excelforum.com/showthread...hreadid=517229

 
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
how do I print multiple print areas on one page Leo18 Excel Discussion (Misc queries) 1 January 11th 10 07:28 PM
Can I adjust print scaling for multiple print areas on the same sh N. Sammons Excel Discussion (Misc queries) 0 June 18th 08 10:24 PM
printing multiple print areas with a print dialog box LHaro Excel Programming 0 August 17th 05 09:56 PM
Set Multiple Print Areas James Hamilton Excel Discussion (Misc queries) 1 June 22nd 05 06:03 AM
Multiple print areas, one worksheet -need to print to PDF! mohagany19 Excel Programming 0 October 6th 04 11:54 PM


All times are GMT +1. The time now is 08:50 AM.

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"