Hi,
I need to combine following codes which will change the attributes of the cell as well as worksheet.
And I need it in single worksheet.
Formula 1
Private Sub Worksheet_Change(ByVal Target As Range)
If Range("I6").Value = "NO" Then
Rows("52:55").EntireRow.Hidden = True
ElseIf Range("I6").Value = "YES" Then
Rows("52:55").EntireRow.Hidden = False
End If
Exit Sub
Formula 2
Private Sub Worksheet_Change(ByVal Target As Range)
If Range("I6").Value = "Yes" Then
Worksheets("Sheet2").Visible = True
Else
Worksheets("Sheet2").Visible = False
End If
End Sub
Thanks in advance.
I need to combine following codes which will change the attributes of the cell as well as worksheet.
And I need it in single worksheet.
Formula 1
Private Sub Worksheet_Change(ByVal Target As Range)
If Range("I6").Value = "NO" Then
Rows("52:55").EntireRow.Hidden = True
ElseIf Range("I6").Value = "YES" Then
Rows("52:55").EntireRow.Hidden = False
End If
Exit Sub
Formula 2
Private Sub Worksheet_Change(ByVal Target As Range)
If Range("I6").Value = "Yes" Then
Worksheets("Sheet2").Visible = True
Else
Worksheets("Sheet2").Visible = False
End If
End Sub
Thanks in advance.