Forum Discussion

Shawky2005's avatar
Shawky2005
Copper Contributor
Feb 24, 2025

Conditional formatting using multiple formulas for the same cell

Greeting experts, I have a table containing hourly bilirubin levels for different gestational ages. I am trying to design an Excel sheet with conditional formatting to give me a red color if the result is higher than the table value and a green color if the result is lower than the table value. All conditional formatting is done using formulas for the same cell. However, I found that I need to make about 1500 conditional formatting rules, every time I make a duplicate for the previous rule and just change the table cell number like the image attached. Is there any method to make all these rules automatic, like what we did when dragging a cell containing a formula to apply it automatically to the other cells?

 

 

  • I don't understand what you are trying to do.

    Could you attach a small sample workbook demonstrating the problem (without sensitive data), or if that is not possible, make it available through OneDrive, Google Drive, Dropbox or similar?

      • HansVogelaar's avatar
        HansVogelaar
        MVP

        On the TcB levels sheet, change E3:J3 to 35, 36, 37, 38, 39, 40.

        On the Calculator sheet, set the fill color of K7 to red. This will be the default.

        Create a single rule for green, with formula

        =I7<INDEX('TcB levels'!E4:J50, XMATCH(G7, 'TcB levels'!D4:D50), XMATCH(E7, 'TcB levels'!E3:J3, -1))

Resources