Results 1 to 2 of 2
  1. #1
    2 Star Lounger
    Join Date
    Jan 2002
    Location
    Delta, Br. Columbia
    Posts
    116
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Strange Cell contents (XP/2003)

    I have a workbook that has the contents of worksheets created from MS Access pasted into it. The resulting data looks fine but all the apparently empty cells appear to have something in them. I have been unable to find out what is there but it means that tests for ISBLANK() do not work. I have also tried ISERR() and the result is negative. However if you go to a blank cell and press the delete key (i.e. clear all) then the ISBLANK() test work.

    I am attaching a sample. The various tests are in columns Q to V. If you "delete" cell B5 you will find the results change.

    Does anyone have any ideas?
    Attached Files Attached Files

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Strange Cell contents (XP/2003)

    This often happens when you import data from another application. You can run a macro to get rid of these blanks-that-are-not-blanks:
    <code>
    Sub ClearBlanks()
    Dim oCell As Range
    For Each oCell In Selection
    If Trim(oCell.Value) = "" Then
    oCell.ClearContents
    End If
    Next oCell
    End Sub
    </code>
    Select a range of cells that includes fake blanks, then run the macro.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •