Print Macro

  • Thread starter Thread starter Sam A
  • Start date Start date
S

Sam A

I have a set of sheets in a workbook where there are two
sections of data per sheet.
The workbook is saved with one set of data pre set in the
print set up.

However, I need to set a macro where the other set of data
per sheet will be printed, and then the print set up
returned to point to the first set of data.

Can I do something with named ranges etc?

Thanking you in advance.
 
You could use this to help you
Sub whatisprintarea()
prntarea = Range("Print_Area").Address
MsgBox prntarea
End Sub

something like this might work

for each ws in worksheets
with ws
..prntarea = Range("Print_Area").Address
..PageSetup.PrintArea = "$B$2:$c$22" 'or whatever
..printpreview
..pagesetup.printarea=prntarea
end with
next
 
Back
Top