View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Frank Kabel Frank Kabel is offline
external usenet poster
 
Posts: 3,885
Default how to delete rows that show no value but contain formulas

Hi
try the following macro:
Sub delete_rows()
Dim lastrow As Long
Dim row_index As Long
Application.ScreenUpdating = False
lastrow = ActiveSheet.Cells(Rows.Count, "A").End(xlUp).Row
For row_index = lastrow - 1 To 1 Step -1
If Cells(row_index, "A").Value= "" and _
Cells(row_index, "A").hasformula then
Rows(row_index).delete
End If
Next
Application.ScreenUpdating = True
End Sub


-----Original Message-----
Hello,

I am trying to find a macro that will delete rows that

show no value or
text but have formulas in them. Can anybody help?

Thank you,
Liliana


---
Message posted from http://www.ExcelForum.com/

.