Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default Printing certain pages within Active Sheets only

I have the following code to print certain page numbers for all the
sheets in my workbook.
Sub Print_All()
Dim sht As Variant
For Each sht In ThisWorkbook.Sheets
sht.PrintOut From:=1, To:=1, Copies:=1, Collate:=True
Next sht
End Sub

But how would I do the same for only the active or sheets selected with
my mouse?


The other problem I have is that there is not much difference in tab
color when I select sheets. Sometimes I make mistakes and type over in
other sheets because I could not tell that more than one was selected.
IS there a way to adjust the color of the tabs once they are selected?
I know I can change the tab colors but not sure if I can do that for
just selected tabs.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Printing certain pages within Active Sheets only

Sub Print_All()
Dim sht As Variant
For Each sht In ActiveWindow.SelectedSheets
sht.PrintOut From:=1, To:=1, Copies:=1, Collate:=True
Next sht
End Sub

--
Regards,
Tom Ogilvy


"gtslabs" wrote:

I have the following code to print certain page numbers for all the
sheets in my workbook.
Sub Print_All()
Dim sht As Variant
For Each sht In ThisWorkbook.Sheets
sht.PrintOut From:=1, To:=1, Copies:=1, Collate:=True
Next sht
End Sub

But how would I do the same for only the active or sheets selected with
my mouse?


The other problem I have is that there is not much difference in tab
color when I select sheets. Sometimes I make mistakes and type over in
other sheets because I could not tell that more than one was selected.
IS there a way to adjust the color of the tabs once they are selected?
I know I can change the tab colors but not sure if I can do that for
just selected tabs.


Reply
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
Excel 2003 printing problem--printing 1 document on 2 pages Bons Excel Discussion (Misc queries) 0 December 24th 09 04:15 PM
How do I delete pages in Excel? Keeps printing blank pages at end. Jojobean Charts and Charting in Excel 1 May 31st 07 07:37 AM
Printing pages from different sheets in a set order Gordana Godzo Excel Programming 1 June 8th 06 08:58 AM
In 3 active sheets in wkbk, determine& display the # of sheets that have data wrpalmer Excel Discussion (Misc queries) 1 November 4th 05 02:01 PM
Code to print most (not all) pages within active workbook AlanN Excel Programming 7 August 8th 03 05:26 PM


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

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"