Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deleting blank cells in a column
I am wanting to select all blank cells in this column, delete the blank cell,
then have the numbers in the colums to the right of them shift over in their place. Is this possible with a code in a macro??? THANKS!!! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deleting blank cells in a column
Give this code a try. Change the range to whatever column you need...
Sub DeleteBlanks() Dim rngToDelete As Range On Error Resume Next Set rngToDelete = Range("A:A").SpecialCells(xlCellTypeBlanks) On Error GoTo 0 If rngToDelete Is Nothing Then MsgBox "Nothin to Delete..." Else rngToDelete.Delete xlToLeft End If End Sub -- HTH... Jim Thomlinson "bodhisatvaofboogie" wrote: I am wanting to select all blank cells in this column, delete the blank cell, then have the numbers in the colums to the right of them shift over in their place. Is this possible with a code in a macro??? THANKS!!! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Deleting blank cells globally | Excel Discussion (Misc queries) | |||
deleting rows with blank cells after a specified column? | Excel Discussion (Misc queries) | |||
Deleting blank cells | Excel Programming | |||
Deleting blank cells in a column | Excel Discussion (Misc queries) | |||
Deleting a row if column K is blank | Excel Programming |