Forum Discussion

Jessica_Leandro's avatar
Jessica_Leandro
Copper Contributor
May 13, 2022

excel

 

 I would like to know how to format paa true or false, a cell that depends on the value of another will have a certain range. For example, c6 will be true if b5 has a value of 5, c6 must be between 310 to 311. if b5 has a value of 6, c6 must be true if it has a value of 311 to 312.

      • HansVogelaar's avatar
        HansVogelaar
        MVP

        Jessica_Leandro 

        Select C6.

        On the Home tab of the ribbon, select Conditional Formatting > New Rule...

        Select 'Use a formula to determine which cells to format'.

        Enter the formula

         

        =OR(AND(B5=5,C6>=310,C6<311),AND(B5=6,C6>=311,C6<312))

         

        Click Format...

        Activate the Fill tab.

        Select a color.

        Click OK, then click OK again.

Resources