+ Reply to Thread
Results 1 to 3 of 3

Color in A1 to define color used by Conditional Formatting?

  1. #1
    Registered User
    Join Date
    10-16-2016
    Location
    Amsterdam
    MS-Off Ver
    2016
    Posts
    1

    Color in A1 to define color used by Conditional Formatting?

    Hello everybody,

    Last few days I've been trying to figure out if it's at all possible to change the color defined in Conditional Formatting based on the color or value of another cell.
    Learned tons.. but still not what I was trying to achieve. Hoping that someone here could shed some light on this for me.

    To explain what I'm trying to achieve in a bit more detail:

    I'm currently working on an adapted ideal-week-calendar in excel (based on https://michaelhyatt.com/ideal-week.html).
    Looking to implement quite some features to this document, but I'm slightly stuck on the color-coding part at this moment.

    On worksheet_Settings I defined a list (list_A) that contains multiple words that are used to color in matching words in the calendar on worksheet_Calendar.
    Applied the following formula to the conditional formatting to get this to work =ISNUMBER(MATCH(Calendar!B2;list_A;0))

    However, I'd like to be able to fill e.g. A1 with 'yellow' wich in turn fills all cells containing a word from list_A with 'yellow'.
    Changing A1 to blue, pink or any color in turn changes the conditional formatting applied to the color as defined in A1.
    Color picking could be through a drop-down menu limiting the color choices slightly OR Just having a blank cell where a color can be filled into

    Does anyone have an idea on how to achieve something like this?
    Any help is majorly appreciated.

    Regards,
    Tom
    Attached Files Attached Files
    Last edited by Monks.; 10-16-2016 at 03:55 PM. Reason: Added workbook for reference

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,064

    Re: Color in A1 to define color used by Conditional Formatting?

    Probably VBA
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,705

    Re: Color in A1 to define color used by Conditional Formatting?

    I tend to agree that a solution as flexible as what you describe would probably require VBA. I might be able to give some guidance.

    Your file does not match what you described (no sheet Calendar, but instead Planner; no name list_A, but instead LIST_1, LIST_2, LIST_3; nothing in cell A1). I get the general idea of what you want but it would help for you to manually set up an example of what you want the result to look like.

    Excel does not have any built-in function that allows you to query the fill color of a cell, which is why VBA is probably required. If you predefine a fixed list of colors you would want to use, it might be possible to create conditional formatting rules to do this, but you would need at minimum a rule for each color, and maybe a rule for each combination of color and row on sheet Settings. If you ever wanted to add or change a color, it would require updates to the CF rules. A VBA solution could be fully automatic.

    Let me know where you want to go from here.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

+ 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] How to get interior.color to use conditional formatting color?
    By tahi.laci in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-28-2015, 12:34 PM
  2. [SOLVED] Conditional Formatting like Color Scale but doing it via Interior.Color
    By Hyflex in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-04-2015, 06:36 AM
  3. Replies: 3
    Last Post: 05-30-2014, 10:24 AM
  4. [SOLVED] Conditional formatting to adapt font color to background color
    By jankee in forum Excel General
    Replies: 4
    Last Post: 08-23-2013, 09:38 AM
  5. [SOLVED] Script which allows user to define the color in conditional formatting
    By PariD in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-13-2012, 03:55 PM
  6. [SOLVED] Conditional color formatting entries have wild color.
    By John Geyer in forum Excel General
    Replies: 0
    Last Post: 02-24-2006, 02:15 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