![]() |
Eliminating rows of data in excel spreadsheet that have blank cell in row A and data in row B - E
I have several rows of data at the bottom of an excel file that I want
to delete. These rows consist of 5 columns of data but in the case of the rows I want to delete there is no data in cell A. This feature only exists in the cells of the rows I want to delete all the other rows have data in column "A". What I need is a macro that will delete the rows that have blank cells in row "A" but have data in row "B" thru "E". |
Eliminating rows of data in excel spreadsheet that have blank cell in row A and data in row B - E
Steven,
If you want to delete all rows in the active worksheet that have a blank cell in column A, this will do it. Activesheet.Columns("A").SpecialCells(xlBlanks).En tireRow.Delete xlShiftUp If you want to operate on a particular workbook, whether or not it is active, this will do it. Workbooks("Book1.xls").Worksheets("Sheet1").Column s("A").SpecialCells(xlBlan ks).EntireRow.Delete xlShiftUp If you want to operate on a worksheet in the workbook where the code resides, this will do it. This workbook.Worksheets("Sheet1").Columns("A").Special Cells(xlBlanks).EntireRow. Delete xlShiftUp Bob Kilmer "Steven R. Berke" wrote in message om... I have several rows of data at the bottom of an excel file that I want to delete. These rows consist of 5 columns of data but in the case of the rows I want to delete there is no data in cell A. This feature only exists in the cells of the rows I want to delete all the other rows have data in column "A". What I need is a macro that will delete the rows that have blank cells in row "A" but have data in row "B" thru "E". |
All times are GMT +1. The time now is 09:21 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com