Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() HI guys, Whats the VBA to select all visible sheets and print them? Visiblesheets.select? Thanks D *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub PrintVisibleSheets()
Dim ws As Worksheet For Each ws In ActiveWorkbook.Worksheets If ws.Visible Then ws.PrintOut Copies:=1, Collate:=True End If Next End Sub --- HTH Jason Atlanta, GA -----Original Message----- HI guys, Whats the VBA to select all visible sheets and print them? Visiblesheets.select? Thanks D *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! . |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks Perfect! - Forgot to ask...if I want to exclude a specifically
named sheet (say called Contents) is that also possible? *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
If your happy with multiple print jobs rather than what you asked then:
Sub PrintVisibleSheets() Dim ws As Worksheet For Each ws In ActiveWorkbook.Worksheets If ws.Visible Then if ws.Name < "Contents" then ws.PrintOut Copies:=1, Collate:=True end if End If Next End Sub -- Regards, Tom Ogilvy "Darin Kramer" wrote in message ... Thanks Perfect! - Forgot to ask...if I want to exclude a specifically named sheet (say called Contents) is that also possible? *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
If you want them as one print job:
Sub SelectVisible() Dim bReplace as Boolean, sh as worksheet Dim shActive as worksheet set shActive = Activesheet bReplace = True For Each sh In ThisWorkbook.Worksheets If sh.Visible Then sh.Select bReplace bReplace = False End If Next ActiveWindow.SelectedSheets.PrintOut shActive.select End Sub -- Regards, Tom Ogilvy "Darin Kramer" wrote in message ... HI guys, Whats the VBA to select all visible sheets and print them? Visiblesheets.select? Thanks D *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
See
http://www.rondebruin.nl/print.htm#visible -- Regards Ron de Bruin http://www.rondebruin.nl "Darin Kramer" wrote in message ... HI guys, Whats the VBA to select all visible sheets and print them? Visiblesheets.select? Thanks D *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how do I select, cut, and paste visible cells only | Excel Discussion (Misc queries) | |||
Select Visible Cells Only | Excel Discussion (Misc queries) | |||
Select visible cells using vba | Excel Programming | |||
Trying to select the visible range of cells | Excel Programming | |||
select visible cells when printing | Excel Programming |