I am very green with Macros. I have a worksheet where a Macro is being used to hide or unhide a separate worksheet based on a dropdown value in a particular cell. My issue is, I need to do this to a 2nd drop down that will hide or unhide a separate worksheet from the previous as well. I am not sure how this should be handled. Below is what I have currently for the first drop down.
Private Sub Worksheet_Change(ByVal Target As Range)If [M19] = "Yes" Then
Sheets("1").Visible = True
Else
Sheets("1").Visible = False
End If
End Sub
This is what I need additionally
Private Sub Worksheet_Change(ByVal Target As Range)If [M20] = "Yes" Then
Sheets("2").Visible = True
Else
Sheets("2").Visible = False
End If
End Sub
Private Sub Worksheet_Change(ByVal Target As Range)If [M19] = "Yes" Then
Sheets("1").Visible = True
Else
Sheets("1").Visible = False
End If
End Sub
This is what I need additionally
Private Sub Worksheet_Change(ByVal Target As Range)If [M20] = "Yes" Then
Sheets("2").Visible = True
Else
Sheets("2").Visible = False
End If
End Sub