Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Private Sub Worksheet_Calculate()
- Dim LastRow As Long, c As Range
- Application.EnableEvents = False
- LastRow = Cells(Cells.Rows.Count, "I").End(xlUp).Row
- On Error Resume Next
- For Each c In Range("B5:B20")
- If (c.Value < DATE AND c.Offset(3,0).Value = 0) Then
- c.EntireRow.Hidden = True
- ElseIf c.Value > DATE Then
- c.EntireRow.Hidden = False
- End If
- Next
- On Error GoTo 0
- Application.EnableEvents = True
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement