Hi all,
I was creating an excel to monitoring the maintenance progress. i would like to hide the row which based on the cell value (date) more than 45days.
i have limited knowledge on VBA here is my core.
i set the date on colum S, and would like to hide the row base on the value on colum . can you point out the erron on my code below?
Sub Hidedatemorethan45days()
'
'
'
Dim cell As Range
For Each cell In Range("S6:S67")
If cell.Value < "45" Then
cell.EntireRow.Hidden = False
End If
If cell.Value > "45" Then
cell.EntireRow.Hidden = True
End If
Next cell
End Sub
thanks in advance
I was creating an excel to monitoring the maintenance progress. i would like to hide the row which based on the cell value (date) more than 45days.
i have limited knowledge on VBA here is my core.
i set the date on colum S, and would like to hide the row base on the value on colum . can you point out the erron on my code below?
Sub Hidedatemorethan45days()
'
'
'
Dim cell As Range
For Each cell In Range("S6:S67")
If cell.Value < "45" Then
cell.EntireRow.Hidden = False
End If
If cell.Value > "45" Then
cell.EntireRow.Hidden = True
End If
Next cell
End Sub
thanks in advance