View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Vergel Adriano Vergel Adriano is offline
external usenet poster
 
Posts: 857
Default Delete Selected Records

maybe something like this:

Sub delete_zero()
Dim lRow As Long
For lRow = 100 To 1 Step -1
With ActiveSheet.Cells(lRow, 1)
If .Text = "0" Then .EntireRow.Delete
End With
Next lRow
End Sub

it will loop through the range A1:A100 going bottom to top.


--
Hope that helps.

Vergel Adriano


"Ian B" wrote:

Hi,

How do I delete an entire rows but only when column A = 0

Thanks


Ian