Hi Excel Experts !
Hope your Thanksgiving was good....
However, for those of us who have to work today
I have a question.
I have a piece of code that I have in many of my workbooks that unhides any/all hidden sheets when I run it. However, it will not unhide ChartSheets.
Can someone please tell me how to select ChartSheets in code ??
Here's my current code:
Sub Unhide()
'
Dim ws As Worksheet
Dim i As Integer
Dim myCounter As Integer
For i = 1 To Worksheets.Count
Set ws = Worksheets(i)
ws.Visible = True
myCounter = myCounter + 1
Next i
MsgBox myCounter & " sheets unhidden!"
End Sub
Thanks !!
Joe in Oxford, CT. USA.
Hope your Thanksgiving was good....
However, for those of us who have to work today

I have a question.
I have a piece of code that I have in many of my workbooks that unhides any/all hidden sheets when I run it. However, it will not unhide ChartSheets.
Can someone please tell me how to select ChartSheets in code ??
Here's my current code:
Sub Unhide()
'
Dim ws As Worksheet
Dim i As Integer
Dim myCounter As Integer
For i = 1 To Worksheets.Count
Set ws = Worksheets(i)
ws.Visible = True
myCounter = myCounter + 1
Next i
MsgBox myCounter & " sheets unhidden!"
End Sub
Thanks !!
Joe in Oxford, CT. USA.
