How to hide and unhide sheet according to drop down list
Hi,
I have a list in one sheet that changes from No 1 to No 50 according to drop down list. Each number is created as separate sheet. But I don't want so many sheets in my workbook when there is only a few list. Let's say when there is only 3 in list, I want to hide the rest 47 sheets in workbook. I tried macro but it doesn't reappear the sheet after changing the list.
Here is my code. Please kindly suggest any improvement to hide and unhide sheets.
Sub HIde()
Sheets("Heading ").Select
Range("B9").Select
If Range("B9").Value = " " Then
Sheets("Saya 1.1 (4.2))").Select
Sheets("Saya 1.1 (4.2)").Visible = False
Else
Sheets("Saya 1.1 (4.2)").Visible = True
End If
End Sub
Thanks in advance.
|