![]() |
IF Statements
Does anyone know how to use an IF statement to change the color of a cell??
An easy example: =IF(A1<=5,1,0). Can I change the value_if_true or value_if_false to change the color of the cell? Could probably read: =IF(A1<=5,1,"cell=green") Thanks. |
IF Statements
Hi,
You can use the Excel feature called COnditional Formating: - Select cell A1 - go to menu Format Conditional Formatting, choose: 'Cell Value Is' 'Greater Than' and enter 5 Click the Format button and choose the green pattern Click OK Click From now on, the cell will be green when the value is greater than 5 and regular format when less than or equal to 5 Regards, Sebastien "Jeff" wrote: Does anyone know how to use an IF statement to change the color of a cell?? An easy example: =IF(A1<=5,1,0). Can I change the value_if_true or value_if_false to change the color of the cell? Could probably read: =IF(A1<=5,1,"cell=green") Thanks. |
IF Statements
Thank you. Just what I needed.
-Jeff "sebastienm" wrote: Hi, You can use the Excel feature called COnditional Formating: - Select cell A1 - go to menu Format Conditional Formatting, choose: 'Cell Value Is' 'Greater Than' and enter 5 Click the Format button and choose the green pattern Click OK Click From now on, the cell will be green when the value is greater than 5 and regular format when less than or equal to 5 Regards, Sebastien "Jeff" wrote: Does anyone know how to use an IF statement to change the color of a cell?? An easy example: =IF(A1<=5,1,0). Can I change the value_if_true or value_if_false to change the color of the cell? Could probably read: =IF(A1<=5,1,"cell=green") Thanks. |
IF Statements
As a follow up question, is there a way to also change the text in the box
when the conditional format is true? For Example: I added CF in cell $B$10 for my summation in $A$10: Condition 1: Formula is, =$A$1=1, format is blue cell Condition 2: Formula is, =$A$1=0, format is red cell I would like to add a changing text with each condition. Any suggestions???? ---------------------------------------- "sebastienm" wrote: Hi, You can use the Excel feature called COnditional Formating: - Select cell A1 - go to menu Format Conditional Formatting, choose: 'Cell Value Is' 'Greater Than' and enter 5 Click the Format button and choose the green pattern Click OK Click From now on, the cell will be green when the value is greater than 5 and regular format when less than or equal to 5 Regards, Sebastien "Jeff" wrote: Does anyone know how to use an IF statement to change the color of a cell?? An easy example: =IF(A1<=5,1,0). Can I change the value_if_true or value_if_false to change the color of the cell? Could probably read: =IF(A1<=5,1,"cell=green") Thanks. |
All times are GMT +1. The time now is 09:08 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com