+ Reply to Thread
Results 1 to 5 of 5

Applying conditional formatting to multiple ranges based on the value of one cell

  1. #1
    Forum Contributor
    Join Date
    10-15-2009
    Location
    Austin, TX - USA
    MS-Off Ver
    Microsoft 365
    Posts
    114

    Applying conditional formatting to multiple ranges based on the value of one cell

    I have a calendar sheet. Each month is a separate block of cells (one cell = one day). There is another separate cell one the sheet where I want to hand-type a random date. I want the conditional formatting to be applied to the correct cell within the correct block based on the date that was hand-typed in that separate cell. As an example, the ranges of two blocks of cells (two months) are $C$5:$I$10 and $K$5:$Q$10. The location of the separate cell is $AQ$15. The conditional formatting that I currently have is "Format only cells that contain" with the cell value equal to =$AQ$15 and it applies to =$C$5:$I$10. How do I add the other block of cells as a separate range to the same rule? I know I can create separate rules for each block (month), but in that case I will end up with quite a number of rules.
    Last edited by chrisneu; 01-21-2017 at 03:01 PM.

  2. #2
    Forum Contributor leo73pk's Avatar
    Join Date
    09-28-2006
    Location
    UAE
    MS-Off Ver
    2016, Microsoft 365
    Posts
    294

    Re: Applying conditional formatting to multiple ranges based on the value of one cell

    Chirsneu,

    you can achieve your goal by defining multiple ranges separated by comma (,) in applies to range. In this manner you can apply same rule to multiple ranges.
    Best Regards,
    Hamza


    It is the greatest of all mistakes to do nothing because you can only do little - do what you can.

  3. #3
    Forum Contributor
    Join Date
    10-15-2009
    Location
    Austin, TX - USA
    MS-Off Ver
    Microsoft 365
    Posts
    114

    Re: Applying conditional formatting to multiple ranges based on the value of one cell

    Hi, leo73pk! Thanks for responding. I tried to separate ranges by comma, but Excel removes the added ranges as soon as I apply the change and returns to previously saved single range.

  4. #4
    Forum Contributor leo73pk's Avatar
    Join Date
    09-28-2006
    Location
    UAE
    MS-Off Ver
    2016, Microsoft 365
    Posts
    294

    Re: Applying conditional formatting to multiple ranges based on the value of one cell

    Do attach your file so members can have a look at the problem

  5. #5
    Forum Contributor
    Join Date
    10-15-2009
    Location
    Austin, TX - USA
    MS-Off Ver
    Microsoft 365
    Posts
    114

    Re: Applying conditional formatting to multiple ranges based on the value of one cell

    leo73pk, I just tried to add multiple ranges by selecting ranges with the mouse and separating each one with a comma and it worked! I tried copy and past the ranges separated by comma multiple times before, but I guess it only works when you actually select ranges. Thank you! The problem is solved.

+ 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. Replies: 1
    Last Post: 08-20-2012, 10:36 PM
  2. Replies: 6
    Last Post: 02-16-2012, 04:52 PM
  3. Applying Conditional Formatting to Non Contiguous Ranges
    By coyle.joe in forum Excel General
    Replies: 1
    Last Post: 01-04-2012, 05:27 PM
  4. Applying conditional formatting to a multiple series chart
    By sikey in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 07-02-2010, 09:55 AM
  5. Replies: 3
    Last Post: 01-26-2010, 08:36 PM
  6. Applying Conditional formatting for entire Row based on date
    By acsishere in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-14-2009, 04:07 PM
  7. Applying Conditional Formatting to Multiple Rows
    By dcaldwell86 in forum Excel General
    Replies: 1
    Last Post: 10-02-2009, 09:32 AM
  8. Replies: 1
    Last Post: 03-22-2006, 02:40 PM

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