Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default How to Select All sheets

Greetings All!

Simple I'm sure but not obvious:

Every month I generate a group of worksheets that will vary in name and
number.

What is the code to select all of the worksheets so that I can apply a
consistent page setup?

(The only examples I have been able to locate always specify worksheet names.)

Then, with the entire workbook selected, I want to select all cells to apply
consistent formatting.

Thanks in advance!

--
Dawn Bjork Buzbee
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default How to Select All sheets

Try this...

Sub SelectAllSheets()
Dim wks As Worksheet

For Each wks In Worksheets
wks.Select False
Next wks
End Sub
--
HTH...

Jim Thomlinson


"Dawn Bjork Buzbee" wrote:

Greetings All!

Simple I'm sure but not obvious:

Every month I generate a group of worksheets that will vary in name and
number.

What is the code to select all of the worksheets so that I can apply a
consistent page setup?

(The only examples I have been able to locate always specify worksheet names.)

Then, with the entire workbook selected, I want to select all cells to apply
consistent formatting.

Thanks in advance!

--
Dawn Bjork Buzbee

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default How to Select All sheets

Thanks Jim-I'll try it!
--
Dawn Bjork Buzbee


"Jim Thomlinson" wrote:

Try this...

Sub SelectAllSheets()
Dim wks As Worksheet

For Each wks In Worksheets
wks.Select False
Next wks
End Sub
--
HTH...

Jim Thomlinson


"Dawn Bjork Buzbee" wrote:

Greetings All!

Simple I'm sure but not obvious:

Every month I generate a group of worksheets that will vary in name and
number.

What is the code to select all of the worksheets so that I can apply a
consistent page setup?

(The only examples I have been able to locate always specify worksheet names.)

Then, with the entire workbook selected, I want to select all cells to apply
consistent formatting.

Thanks in advance!

--
Dawn Bjork Buzbee

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
sheets.select kurt Excel Programming 2 November 28th 05 04:34 PM
select sheets snax500[_2_] Excel Programming 6 June 8th 05 04:48 AM
How to select other sheets using ADO farmer[_2_] Excel Programming 2 October 24th 04 06:56 PM
select a1 on all sheets Piers Clinton-Tarestad Excel Programming 1 October 1st 03 08:34 PM
select sheets by name - how? Walt[_2_] Excel Programming 5 July 30th 03 10:42 PM


All times are GMT +1. The time now is 09:14 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"