0
votes

first of all: I am using Excel 2007 with a .XLS file.

I have a column that contains some cells with values but other random cells are in "blank". But when I do ISBLANK on this cells it returns me FALSE on all of them. So I assume they contain a value, and I want them really blank (only the cells I see without values).

I already tried replacing spaces with nothing, and nothing with nothing but still not working.

Thanks.

1
So you are trying to create a truly empty cell? Just hit the DELETE key when selected?BruceWayne
Can you show us the code you're using?Frecklefoot
What happens if you just click on the cell and click delete on your keyboard?jcarroll
My guess is you have a non-display character in that field.xQbert
In a empty column use this =Trim(Clean(A1)) and copy down. Where A1 is the first cell in your column you are testing. Then copy and paste the values back.Scott Craner

1 Answers

1
votes

Select the cells you wish to cleanup and run:

Sub KleanUp()
    Dim rng As Range, r As Range

    Set rng = Intersect(Selection, ActiveSheet.UsedRange)
    For Each r In rng
        If r.Value = "" Then r.Clear
    Next r
End Sub