Go to all "FALSE" cells

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I need the "go to" feature to find all the cells that are FALSE then delete
and move up all of the rows that have FALSE in the selected column. The
particular column I am addressing will either have a number or FALSE and
nothing else. Thanks.
 
Use data>filter>autofilter, filter on FALSE and delete the visible rows but
the top row (header row)
 
ONe way:

Public Sub DeleteFalseRows()
Dim rDelete As Range
On Error Resume Next
Set rDelete = Columns("D").Cells.SpecialCells( _
xlCellTypeConstants, xlLogical)
On Error GoTo 0
If Not rDelete Is Nothing Then rDelete.EntireRow.Delete
End Sub

Change the column number to suit.

This assumes that FALSE is entered as a constant. If it's the result of
a formula, substitute xlCellTypeFormulas for xlCelllTypeConstants
 
Back
Top