ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Print IF return "OK" or "NOT OK" in different colors (https://www.excelbanter.com/excel-discussion-misc-queries/86223-print-if-return-ok-not-ok-different-colors.html)

Mbtgb

Print IF return "OK" or "NOT OK" in different colors
 
I am using an IF statement that returns an "OK" or "NOT OK" statement. Can I
get the "OK" to print in Green and the "NOT OK" to print in Red.

Chip Pearson

Print IF return "OK" or "NOT OK" in different colors
 
You can use Conditional Formatting from the Format menu to do
this.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Mbtgb" wrote in message
...
I am using an IF statement that returns an "OK" or "NOT OK"
statement. Can I
get the "OK" to print in Green and the "NOT OK" to print in
Red.




Biff

Print IF return "OK" or "NOT OK" in different colors
 
Hi!

Try this:

Assume that formula is in cell A1.

Select cell A1
Goto FormatConditional Formatting

Condition 1
Select Formula Is from the drop list
Enter this formula in the little box to the right:

=A1="OK"

Click the Format button
Set the font color to be GREEN

Click OK

Click the Add button

Condition 2
Select Formula Is from the drop list
Enter this formula in the little box to the right:

=A1="Not OK"

Click the Format button
Set the font color to be RED

OK out

Biff

"Mbtgb" wrote in message
...
I am using an IF statement that returns an "OK" or "NOT OK" statement. Can
I
get the "OK" to print in Green and the "NOT OK" to print in Red.





All times are GMT +1. The time now is 02:28 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com