T
TiscaliNews
Using xl2000. In a range of approx 12000 rows, I am deleting rows that match
17 different criteria. Is there an easy way to include the first row?
The main code is a variation on one of Chip Pearson's posts and runs from
the bottom of the range and works upwards using:
Range([a1], [a65536].End(xlUp)).Select
ColNum = Selection(1).Column
For RowNdx = Selection( _
Selection.Cells.Count).Row To _
Selection(1).Row + 1 Step -1
'Times before 07:40
If Cells(RowNdx, ColNum).Offset(0, 1).Value < 0.319444 Then
Cells(RowNdx, ColNum).EntireRow.Delete
End If
Next RowNdx
i.e., for the above code, if B1 contains, say, 06:30, the above code does
all the rest, but not the first row. Should I just include a "control row"
at the top or is there a better way?
Martin
17 different criteria. Is there an easy way to include the first row?
The main code is a variation on one of Chip Pearson's posts and runs from
the bottom of the range and works upwards using:
Range([a1], [a65536].End(xlUp)).Select
ColNum = Selection(1).Column
For RowNdx = Selection( _
Selection.Cells.Count).Row To _
Selection(1).Row + 1 Step -1
'Times before 07:40
If Cells(RowNdx, ColNum).Offset(0, 1).Value < 0.319444 Then
Cells(RowNdx, ColNum).EntireRow.Delete
End If
Next RowNdx
i.e., for the above code, if B1 contains, say, 06:30, the above code does
all the rest, but not the first row. Should I just include a "control row"
at the top or is there a better way?
Martin