Good afternoon,
I think this maybe a simple one, but I have no idea why an error has started suddenly when the code below works in another sheet
I have 2 subs() 1 to hide and 1 to unhide, but I am getting a 'Run-timer error '1004': Application-defined or object-defined error" and I am lost with it.
even if I change the xlVeryHidden to True I still get the same error.
Any idea what I am doing wrong, thanks in advance
I think this maybe a simple one, but I have no idea why an error has started suddenly when the code below works in another sheet
I have 2 subs() 1 to hide and 1 to unhide, but I am getting a 'Run-timer error '1004': Application-defined or object-defined error" and I am lost with it.
even if I change the xlVeryHidden to True I still get the same error.
Code:
Private Sub RevealSheets()
Sheet1.Visible = True
Sheet2.Visible = True
Sheet3.Visible = True
Sheet4.Visible = True
Sheet5.Visible = True
Sheet6.Visible = True
Sheet7.Visible = True
Sheets("Welcome Page").Select
End Sub
Private Sub HideSheets()
Sheet1.Visible = xlVeryHidden
Sheet2.Visible = xlVeryHidden
Sheet3.Visible = True
Sheet4.Visible = xlVeryHidden
Sheet5.Visible = xlVeryHidden
Sheet6.Visible = xlVeryHidden
Sheet7.Visible = xlVeryHidden
Sheets("Welcome Page").Select
End Sub
Any idea what I am doing wrong, thanks in advance