View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jean-Paul Viel Jean-Paul Viel is offline
external usenet poster
 
Posts: 39
Default checking visible sheets.

Hi,



Use this macro :



Sub ScanSheet()

Dim ws As Worksheet

For Each ws In Worksheets

If ws.Visible Then

' your code

MsgBox ws.Name

End If

Next ws

End Sub




--
JP

http://www.solutionsvba.com


"Scott" wrote in message
...
Hi,

Can someone please help,

I'm trying to create this code which does the following:-
check visible sheets only, not hidden sheets.

check the first sheet
if it is equal to a list of names in an array then goto the next sheet
if it is not equal to a any of the names in an array then do some code
(which I have created)
then goto the next sheet and do the same again

Can someone please help,
Thanks
Best regards,
Scott