There are two ways that I know of to take away the blank cells, I dont know
about the zeros...
Manually you can do this by
Edit Go To Special Blanks
Edit Delete Shift Entire Row
That is starting on A1
There is a code as well
Option Explicit
Sub testme01()
Dim myRng As Range
With ActiveSheet
Set myRng = Nothing
On Error Resume Next
Set myRng = .Range("a:a").Cells.SpecialCells(xlCellTypeBlanks)
On Error GoTo 0
If myRng Is Nothing Then
MsgBox "no blanks in column A"
Exit Sub
End If
Intersect(myRng.EntireRow, .Columns("A:P")) _
.Cells.SpecialCells(xlCellTypeBlanks).Delete shift:=xlUp
End With
End Sub
test it, select the column and play that macro
--
If this reply was helpful, please indicate that your question has been
answered to help others find anwsers to similar questions.
www.silverbirddesigns.com
Fighting Texas Aggie Class of 2009
"ekkeindoha" wrote:
Need to know a formula to remove blank cells or cells containing 0.
eg
A
21
0
33
44
0
What I'm looking for are
A
21
33
44
No zero or blank cells.
thx