Colour coding a grade in a cell based on a grade in another cell

1.4k views Asked by At

I am using google sheets and I want to be able to colour code a grade achieved by a student (in cell E2) based on their target grade (in cell D2). The grades will be iN letters and are A,B,C,D,E,F,G,U. If their grade is higher than target grade the cell will turn green, if equal the cell will turn yellow and if their grade is less than target it will turn red.

Can this be done?

1

There are 1 answers

1
MikeyB On BEST ANSWER

Yes, this can be done.

To apply conditional formatting to cell E2, select the cell, and then go to Format > Conditional Formatting. In the dropdown on the left of the Conditional Formatting menu, select "Custom Formula is", then enter the following formula in the cell:

=E2>D2

Then select the red background colour. Add another rule by selecting "+ add another rule", and after selecting "Custom Formula is" from the dropdown menu, enter the following formulae and colours:

=E2<D2     -     Green
=E2=D2     -     Yellow

Hope that helps!