Loop through column(s) to check values, perform action based on ch
Hi,
This looks at the used range in column A and hides the row if the cell value
is equal to XXXXX
Sub stantial()
lastrow = Range("A65536").End(xlUp).Row
For x = lastrow To 1 Step -1
If Cells(x, 1).Value = "XXXXX" Then 'change to suit
Rows(x).EntireRow.Hidden = True
End If
Next
End Sub
Mike
"ward376" wrote:
I hope someone has something like this worked out - How to loop
through a column and if every cell contains a certain value (i.e.all
zeros), hide or delete the column.
Thanks!
ward376
|