Bass71
MIS
- Jun 21, 2001
- 79
Hi;
In a range of 1 X 6,I'm trying to hide rows those rows whose cells meet the criteria of either containing the string "PH" or a combination of nulls and "PH". Any other strings found in any given row, with or without nulls, would necessitate keeping row visible. Here's what I've got thus far...
Range("A1").Select
Dim c As Range
For Each c In Range(ActiveCell.Offset(0, 0), ActiveCell.Offset(0, 6))
If c.Value = "PH" Or c.Value <> "" Then
Selection.EntireRow.Hidden = True
ActiveCell.Offset(1, 0).Select
Else
ActiveCell.Offset(1, 0).Select
End If
Next
Thanks..........RO
In a range of 1 X 6,I'm trying to hide rows those rows whose cells meet the criteria of either containing the string "PH" or a combination of nulls and "PH". Any other strings found in any given row, with or without nulls, would necessitate keeping row visible. Here's what I've got thus far...
Range("A1").Select
Dim c As Range
For Each c In Range(ActiveCell.Offset(0, 0), ActiveCell.Offset(0, 6))
If c.Value = "PH" Or c.Value <> "" Then
Selection.EntireRow.Hidden = True
ActiveCell.Offset(1, 0).Select
Else
ActiveCell.Offset(1, 0).Select
End If
Next
Thanks..........RO