• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

'P' in green font; 'F' in red.

I'm doing a simple report of students in a Pass/Fail situaton.
If a student obtains the required min marks, Excel displays a 'P' in the resp. row to indicate Pass; or 'F' to indicate Fail.
The above can be done using the IF fxn.
But I would like the letter 'P' to assume a green font and the letter 'F' to assume a red font.
That's my Excel-question.
Thank you, friends.
 
Hi James ,

This is a very straightforward application of Conditional Formatting.

Select your entire range for the grade ; let us assume it is J7 through J33.

Put in two custom formulae for the CF , one for selecting a font of GREEN color , and the other for selecting a font of RED color.

The formula for selecting GREEN color will be =$J7="P"

The formula for selecting RED color will be =$J7 = "F"

This will ensure that whenever your IF formula puts in a P in any cell in this range , it will satisfy the first rule and will appear in GREEN font ; any F in this range will satisfy the second rule , and will appear in RED font.

Narayan
 
Back
Top