+ Reply to Thread
Results 1 to 2 of 2

Removing Blanks not working

  1. #1
    Registered User
    Join Date
    01-15-2013
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    7

    Removing Blanks not working

    Good Morning,

    I have written a macro that pulls data from another workbook, formats the data and then removes 'blank' records into another worksheet. The remove blank code looks like this
    Please Login or Register  to view this content.
    LRlimit is a recordcount done previous, and the worksheet is correct.
    To sum this up easily, the code looks for records that are incomplete, copies the row to my 'dump' sheet and then delets the record from the main sheet.
    The problem that i am having, is that some records that contain blank cells are not being copied, and I can't figure out why. I have had an instance where the code has picked up one record, and left another that is pretty much identical. I have checked these cells and they do really contain nothing, not spaces,special chars or farmula so I can't figure out why it would not work

    Any help would be greatly appreciated

    P

  2. #2
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Removing Blanks not working

    Assuming that this line is dump.Cells(i, 1)
    correct,Try this one

    Please Login or Register  to view this content.
    cell.EntireRow.Delete
    i = i + 1
    End If
    Next cell[/CODE]

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1