ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Way to print every worksheet in a workbook except the first two (https://www.excelbanter.com/excel-programming/415297-way-print-every-worksheet-workbook-except-first-two.html)

[email protected]

Way to print every worksheet in a workbook except the first two
 
Does anyone know a way to write VBA code that allows excel to print
every worksheet in a workbook except the first two worksheets? Any
help you could offer would be greatly appreciated.

Thanks

Chip Pearson

Way to print every worksheet in a workbook except the first two
 
Try code like

Sub AAA()
Dim N As Long
With ActiveWorkbook.Worksheets
For N = 3 To .Count
.Item(N).PrintOut
Next N
End With
End Sub


--
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)



wrote in message
...
Does anyone know a way to write VBA code that allows excel to print
every worksheet in a workbook except the first two worksheets? Any
help you could offer would be greatly appreciated.

Thanks



[email protected]

Way to print every worksheet in a workbook except the first two
 
On Aug 6, 6:53*pm, "Chip Pearson" wrote:
Try code like

Sub AAA()
* * Dim N As Long
* * With ActiveWorkbook.Worksheets
* * * * For N = 3 To .Count
* * * * * * .Item(N).PrintOut
* * * * Next N
* * End With
End Sub

--
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
* * Excel Product Group
Pearson Software Consulting, LLCwww.cpearson.com
(email on web site)

wrote in message

...



Does anyone know a way to write VBA code that allows excel to print
every worksheet in a workbook except the first two worksheets? *Any
help you could offer would be greatly appreciated.


Thanks- Hide quoted text -


- Show quoted text -


Worked perfectly. Many thanks.


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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com