+ Reply to Thread
Results 1 to 3 of 3

Delete row based on cell FORMAT (color, font, etc) (not based on cell value)

  1. #1
    Registered User
    Join Date
    12-11-2012
    Location
    Florida
    MS-Off Ver
    Excel 2007
    Posts
    2

    Exclamation Delete row based on cell FORMAT (color, font, etc) (not based on cell value)

    I need a macro that will delete all rows with cells that contain a certain format in column A. Specifically, I want to delete all rows that have black text in column A.

    A little history on this: I need to isolate duplicated values. My duplicated values are highlighted in light red and front is red. I need to keep those, and delete everything else. Thus why I want to delete rows with BLACK text in column A.

    I will also need a macro that will delete rows with blank cells in column B - but that can wait as I need to do the other thing first.

    Thank you,
    trobey

  2. #2
    Forum Contributor
    Join Date
    01-02-2007
    Location
    Australia NSW
    MS-Off Ver
    2013
    Posts
    494

    Re: Delete row based on cell FORMAT (color, font, etc) (not based on cell value)

    How about something like:
    Please Login or Register  to view this content.
    Last edited by coreytroy; 12-11-2012 at 08:15 PM.

  3. #3
    Registered User
    Join Date
    12-11-2012
    Location
    Florida
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Delete row based on cell FORMAT (color, font, etc) (not based on cell value)

    Hi, thank you for your reply.

    The code did not work as needed. It ended up deleting all the red cells. I did tweak the code a little (I took a basic VB class waaaay back in college, but I barely remember a thing) and my tweaks did change the outcome but I never got the desired outcome. Since your original code was doing the opposite of what I wanted, deleting the red cells and not the black cells, I decided to highlight unique cells instead of the duplicates; thus making the unique cells red and the duplicates unformated black. I ran the macro again it deleted the duplicates again, even though they had no format change.

    So long story short, the code didn't work. Thank you for your help though, and I am more than willing to try another idea you may have.

    And does anyone else want to give it a shot?

    Thanks to all,
    trobey

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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