+ Reply to Thread
Results 1 to 2 of 2

Unhide hidden sheets

  1. #1
    Minos
    Guest

    Unhide hidden sheets

    I found that to unhide hidden sheets in Excel you have to do one by one or
    sheet by sheet. Is there a way by which I can a select more than one sheet to
    unhide and unhide them simultaneously instead of doing it one by one?


    Minos

  2. #2
    Dave Peterson
    Guest

    Re: Unhide hidden sheets

    You always have to have at least one sheet visible, but you could use code like
    this:

    Option Explicit
    Sub UnhideAll()
    Dim wks As Object
    For Each wks In ActiveWorkbook.Sheets
    wks.Visible = xlSheetVisible
    Next wks
    End Sub

    Sub HideSelected()
    Dim wks As Object
    On Error Resume Next
    For Each wks In ActiveWindow.SelectedSheets
    wks.Visible = xlSheetHidden
    If Err.Number <> 0 Then
    MsgBox wks.Name & " was not hidden"
    Err.Clear
    End If
    Next wks
    On Error GoTo 0
    End Sub

    The second procedure hides the sheets that are grouped--click on the first sheet
    tab and ctrl-click on subsequent.


    Minos wrote:
    >
    > I found that to unhide hidden sheets in Excel you have to do one by one or
    > sheet by sheet. Is there a way by which I can a select more than one sheet to
    > unhide and unhide them simultaneously instead of doing it one by one?
    >
    > Minos


    --

    Dave Peterson

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1