+ Reply to Thread
Results 1 to 2 of 2

Set the color of a cell based on the color and text of another cell.

  1. #1
    Registered User
    Join Date
    09-07-2019
    Location
    Florida
    MS-Off Ver
    16.16.13
    Posts
    1

    Set the color of a cell based on the color and text of another cell.

    I am looking for a formula that does one of the following:
    If a cell with text is filled with a color, then all other cells with the same text will automatically be filled with the same color.
    OR
    If a cell with text is filled with a color, then entering the same text in a cell will automatically fill with the same color.
    OR
    Setting a cell equal to the same text and color fill as another.

    For context, I have a sheet with many rows with 9 columns. For every row, the first 2 cells contain different text and one of them will eventually be filled yellow. The other 7 columns contain text from either one of the first two. I want so that when I fill one of the first 2 yellow, the other cells that contain the same text will automatically be filled with the same color.

    I'm guessing this can be done by formulas with conditional formatting or maybe VBA, but I'm not sure.

    Thank you!

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

    Re: Set the color of a cell based on the color and text of another cell.

    Dunno if this has changed recently but formulas cannot read the colours of cells unless the cell has been filled using Condtional Formatting (in which case just use the same codntion to dtermine if the cell is filled with a specific colour), otherwise VBA would be you're only solution. But as you've posted this in the formula area, I'm assuming that's the solution you prefer which as stated may not be possible.

    You can read the contents of a cell and set the colour accordingly.

    Post a sample spreadsheet with expected results, remove any sensitive data, create a mockup example if necessary.
    Use the Go Advanced option at the bottom of the page then scroll down to Manage Attachments as the "paperclip" method does not work on this forum.
    Last edited by Special-K; 09-09-2019 at 05:48 AM.
    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.

+ 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. VBA Set Color Text Variable based on color entry in a cell?
    By learning new things in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-18-2018, 11:18 AM
  2. Change cell format (cell color+font color) based on color of another cell
    By Dedaluss in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-30-2017, 03:27 AM
  3. Swapping cell content to INCLUDE CELL FORMATTING (Text color, background color, etc)
    By jcpeterson in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-10-2014, 10:09 AM
  4. Macro to change cell text color based on darkness of cell fill color
    By cincyshirm61 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-25-2014, 12:11 PM
  5. Replies: 4
    Last Post: 12-29-2013, 11:41 PM
  6. [SOLVED] Color-format a cell which contains data in a column based on the color of another cell
    By Nit3hawK in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-27-2013, 05:25 PM
  7. change text color based on adjacent cell text color
    By matthewst in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 03-01-2005, 03:49 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