I use this code to hide or show some worksheets:
If btnShowHideProject.Caption = "Hide Project" Then
sh_ProjSummary.Visible = xlSheetVeryHidden
sh_ProjStart.Visible = xlSheetVeryHidden
sh_ProjEnd.Visible = xlSheetVeryHidden
btnShowHideProject.Caption = "Show Project"
Else
sh_ProjSummary.Visible = xlSheetVisible
sh_ProjStart.Visible = xlSheetVisible
sh_ProjEnd.Visible = xlSheetVisible
btnShowHideProject.Caption = "Hide Project"
End If
Use the button's caption to indicate its state. If, when you press it, it says "hide", you hide the rows and set it to "show".
Regards, TMS
Bookmarks