Archive of Mr Excel Message Board


Back to Printing in Excel archive index
Back to archive home

Marco to print

Posted by Paul Bridges on October 23, 2001 8:36 AM
I need a Marco to print sheet 1 range A1:AK29, it also needs to print sheet 2 range A1:AK29 if sheet 2 cell G29 has anything in it. Excel’97 Thanks

Re: Marco to print

Posted by Juan Pablo on October 23, 2001 9:20 AM
Sub PrintA1AK29()
With Sheets("Sheet1")
.PageSetup.PrintArea = "$A$1:$AK$29"
.PrintOut
End With
With Sheets("Sheet2")
If .[G29] <> "" Then
.PageSetup.PrintArea = "$A$1:$AK$29"
.PrintOut
End If
End With

End Sub

Juan Pablo


Thanks

Posted by Paul Bridges on October 23, 2001 11:09 AM


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.