+ Reply to Thread
Results 1 to 5 of 5

Delete any row WITH a red fill color (background)

  1. #1
    Registered User
    Join Date
    05-12-2011
    Location
    richmond
    MS-Off Ver
    Excel 2003
    Posts
    3

    Delete any row WITH a red fill color (background)

    I need to delete the entire row that includes a cell with a red background. For instance, if cell G7 is the only cell with a red background then I want the entire row 7 deleted AND moved up.

    -A1:W25,000 (All of these cells have integers in it)
    -I already run a macro to fill a cell red as needed based on my reason (NO CONDITIONAL FORMATTING USED HERE)
    -I need any row with 1 or more cells, with the color red, to be deleted and moved up.


    Thanks in advance for your help!!!

    -Altan

  2. #2
    Valued Forum Contributor realniceguy5000's Avatar
    Join Date
    03-20-2008
    Location
    Fl
    MS-Off Ver
    Excel 2003 & 2010
    Posts
    951

    Re: Delete any row WITH a red fill color (background)

    Hi,

    One way,

    Please Login or Register  to view this content.
    Thank You, Mike

    Some Helpful Hints:

    1. New members please read & follow the Forum Rules
    2. Use Code Tags...Place[code]Before the first line and[/code] After the last line.
    3. If you are pleased with a solution mark your post SOLVED.
    4. Thank those who have help you by clicking the scales at the top right of the post.

    Here...

  3. #3
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Delete any row WITH a red fill color (background)

    hi, aorum, can you post sample workbook showing original data and the result you need (10-15 rows will be sufficient)

  4. #4
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Delete any row WITH a red fill color (background)

    please check attachment, run code "test"
    Attached Files Attached Files

  5. #5
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Delete any row WITH a red fill color (background)

    Hello aorum,

    Here is another fast method.
    Please Login or Register  to view this content.
    Last edited by Leith Ross; 05-14-2011 at 04:25 PM. Reason: Added Application.ScreenUdating code
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

+ 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