+ Reply to Thread
Results 1 to 8 of 8

Highlighting alternating clusters of rows

  1. #1
    Registered User
    Join Date
    07-21-2015
    Location
    USA
    MS-Off Ver
    Excel 2007 (Windows & Mac)
    Posts
    6

    Exclamation Highlighting alternating clusters of rows

    Hi,

    The picture below should illustrate what I'm trying to do. All the tutorials I've looked at so far are limited to conditional formatting for strictly alternating rows, whereas the database I'm building often has clusters of rows as defined by merged cells in the first and second columns.

    Any advice would be greatly appreciated. Thanks.

    Screen Shot 2015-07-21 at 10.42.20 AM.png

  2. #2
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,684

    Re: Highlighting alternating clusters of rows

    Use conditional formatting based on formula. for instance on similar to such one:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    this is for one color the other (when the condition is not met - format as standard fill of cells).

    see attachment
    Attached Files Attached Files
    Best Regards,

    Kaper

  3. #3
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,684

    Re: Highlighting alternating clusters of rows

    of course instead of MOD(...,2) you could use ISODD(...) or ISEVEN(...)

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,968

    Re: Highlighting alternating clusters of rows

    Kaper, that will work for 2 rows, but not 3?
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  5. #5
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,684

    Re: Highlighting alternating clusters of rows

    Hi Ford,
    I think will work for any number 1,2,3 etc rows in a cluster.
    Note that formula refers to column A, where for each cluster is only one merged cell.

    PS. see the attachment :-)

  6. #6
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,968

    Re: Highlighting alternating clusters of rows

    My apologies, you are correct

  7. #7
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,684

    Re: Highlighting alternating clusters of rows

    My pleasure,
    and thanks for reputation

  8. #8
    Registered User
    Join Date
    07-21-2015
    Location
    USA
    MS-Off Ver
    Excel 2007 (Windows & Mac)
    Posts
    6

    Re: Highlighting alternating clusters of rows

    Thanks for the quick help, Kaper. A couple of questions:
    1. How would I modify the code to incorporate two alternating colors instead of (one color)+(no color)?
    2. When I apply filters to the column with merged cells (or any of the subsequent columns, for the matter), the alternating color scheme effectively doesn't work because it doesn't take into account visible vs. hidden rows. Would it be possible to have the formatting account for this?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Alternating Color Rows
    By madnhain in forum Excel General
    Replies: 6
    Last Post: 01-12-2015, 06:13 PM
  2. Highlight alternating rows
    By Ocean Zhang in forum Excel General
    Replies: 1
    Last Post: 08-05-2013, 09:31 PM
  3. [SOLVED] Create alternating rows
    By Scibola in forum Excel General
    Replies: 2
    Last Post: 04-09-2013, 04:19 PM
  4. *Shade* alternating rows
    By BobJones in forum Excel General
    Replies: 9
    Last Post: 09-17-2011, 02:19 AM
  5. Sort rows and color alternating rows using VB
    By drewship in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 11-12-2010, 10:10 AM
  6. Excel 2007 : Alternating colors in rows...
    By racinjason1978 in forum Excel General
    Replies: 4
    Last Post: 10-02-2009, 05:08 PM
  7. insert alternating columns and rows
    By iturnrocks in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-12-2007, 05:23 PM

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