Delete Entire Row based ALL Blank Cells and Formula Errors

newatmacros

New Member
Joined
Jun 23, 2016
Messages
18
I have been exhausting myself trying to appropriately create a macro that delete entire rows in my worksheet A2:LastRow of data based on certain criteria
I have been working on creating a macro that deletes entire rows of all data if anywhere in the row there is a blank cell. Unfortunately, the ones that I have created always come up in an error due to overlapping with some rows containing more than one blank cells. I also need to add to this formula to delete rows if it has an error formula. Again, I encountered the same error with creating this as well.
One macro for both of these commands is ideal.
Any help will be greatly appreciated!
Thanks!
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
You said:
"that deletes entire rows of all data if anywhere in the row there is a blank cell"

So each row has 16,384 cells so are you saying you really have all 16,384 cells filled with data sometimes.
 
Upvote 0
Hi My Answer Is This!
Thanks for responding. Well I am creating this macro to deal with data that may not be consistent. Basically I need it to check to the last cell of the data in the row. So, it doesn't have to search 16,384 cells; but it has to be designed to search through each data filled cell of each row no matter what has been placed in the worksheet. Does this answer your question?
 
Upvote 0
So your not able to provide what is the last column to look in?
Will the last column to look in always have a header in row (1)
If neither of these questions can be answered then how do I know what is the last column to look in.
We are not looking for cells with data we are looking for cells with no data.
So for example if row 3 had data in all cells all the way over to column 12
But row 4 only had data in all cells all the way to column 3 then this row would be deleted.

And when you say delete the row of all data does that mean clear the row of all data or delete the row.
 
Upvote 0
Hi My Answer Is This!
The thing is the headers may change. I actually don't want to do anything in the headers. I want to select and search through all of the data below the headers. So if one entire row has just one blank cell, I want the whole row deleted, just like you would manually delete and all the cells would automatically move up. Does that make sense?
I know there must be away to have a search that just goes through the first cell of data and ends at the last cell of data; however, I don't know how to do this with rows.
 
Upvote 0

Forum statistics

Threads
1,214,590
Messages
6,120,421
Members
448,961
Latest member
nzskater

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top