LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default Select some sheets automatically

I am trying to write a routine to select all sheets that have (1) at the end
of the sheet name. This is what I have so far, can anyone help?

Thanks

Sub Select_1()

Dim SelectedSheets As String
Dim ws As Worksheet

For Each ws In ActiveWorkbook.Worksheets
If ws.Name Like "*(1)" Then
SelectedSheets = SelectedSheets + ", " + ws.Name
End If
Next ws
Sheets(SelectedSheets).Select

End Sub
 
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
Automatically select read-only [email protected] Excel Discussion (Misc queries) 2 February 22nd 06 10:21 AM
select listbox item automatically ilyaskazi[_71_] Excel Programming 3 September 14th 05 12:27 PM
Need Way to Automatically Select Data Art Stewart Excel Worksheet Functions 4 March 21st 05 01:32 AM
Need Way to Automatically Select Data Arthur Moore Excel Discussion (Misc queries) 0 March 19th 05 12:32 AM
automatically select last value in a column Jon Horvath Excel Worksheet Functions 2 December 23rd 04 07:47 PM


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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"