LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Deleting rows when certain cells are blank

Hi,

I am using this code to delete the row if the cell in column A is blank.
Dim i, j As Integer
Set starta = ActiveSheet.Range("a2")
LR = ActiveSheet.Range("a" & Rows.Count).End(xlUp).Offset(1, 0).Row
For i = LR To 0 Step -1
If starta.Offset(i, 0).Value = 0 Then starta.Offset(i, 0).EntireRow.Delete
Next i

I would then like to delete a row if the cells in columns B, C, D, and E are
all blank even if the cell in column A is not blank

Any ideas?
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
deleting rows with blank cells after a specified column? MYR Excel Discussion (Misc queries) 3 January 9th 09 09:13 PM
Deleting blank cells w/o impacting other rows/columns ShagNasty Excel Programming 5 October 26th 08 04:34 PM
Deleting blank (Cells/Rows) in Excel-VBA VexedFist Excel Programming 1 April 6th 07 05:08 AM
Deleting rows with blank cells jim_0068 Excel Programming 15 April 7th 06 08:00 AM
Deleting rows with blank cells Batman Excel Worksheet Functions 10 February 16th 05 06:01 PM


All times are GMT +1. The time now is 09:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"