I am trying to delete an entire row if cells between a certain range are all blank.
For example, for the range B6-H10, if the values from B6-H6 are blank, then delete row 6. It is worth noting that Column A will be populated for the entirety of the range.
At present, the following error is being returned:
'Cannot use that command on overlapping sections'
I believe this error occurs as a result of a value being present within one of the cells within the given range.
The code at present can be found below:-
Public Sub DeleteERows()
Dim rng As Range
Set rng = Range("B6:H10")
rng.SpecialCells(xlCellTypeBlanks).EntireRow.Select
rng.SpecialCells(xlCellTypeBlanks).EntireRow.Delete
End Sub
Any thoughts much appreciated.