I saw this on the message board, which works to hide all sheets but Sheet1. How do I modify it to hide all sheets except Sheet 1 and Sheet2?
Dim sht As Object
For Each sht In Sheets
If sht.Name <> "Sheet1" Then
sht.Visible = xlSheetHidden
End If
Next sht
Dim sht As Object
For Each sht In Sheets
If sht.Name <> "Sheet1" Then
sht.Visible = xlSheetHidden
End If
Next sht