Hi All,
For some reason, my macro is not working. Will you please let me know where I am going wrong? I want to hide a few rows if one cell value is over 15k, if it is <=15000, then should show. See my code below:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Range("C18").Value > 15000 Then
Rows("20:46").EntireRow.Hidden = True
Else
Rows("20:46").EntireRow.Hidden = False
End If
End Sub
Please help!
For some reason, my macro is not working. Will you please let me know where I am going wrong? I want to hide a few rows if one cell value is over 15k, if it is <=15000, then should show. See my code below:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Range("C18").Value > 15000 Then
Rows("20:46").EntireRow.Hidden = True
Else
Rows("20:46").EntireRow.Hidden = False
End If
End Sub
Please help!