Conditional formatting: Highest and lowest value by row

Solved
Hello,

I'm reaching out to the community for help with a problem I can't seem to solve.
I want to format (red or green background) the highest and lowest value on each row of my table (which contains 4 columns and over a hundred rows).

Is there a formula or trick to highlight these values by row?

Thank you,

4 answers

  • Votes
  • Date
  • Descending date
  1. Hello

    For data in columns A,B,C,D starting in row 1

    select A1:D100 and open the conditional formatting / choose the last "Use a formula..."

    For green (lowest value) use this formula
    =A1=MIN($A$1:$D$1) and choose green fill format

    Click on new formula

    For red (highest value) use this formula
    =A1=MAX($A$1:$D$1) and choose red fill format

    Best regards
    1. Contributor
      Hello (everyone)
      papyluc, just a small correction to make it work line by line:
      =A1=MIN($A1:D1)
      so no $ in front of the 1
      thanks
    2. @VaucluseGreetings

      Indeed, a typo in my typing

      Best regards
    3. Contributor
      @PapyLuc51No problem, Papyluc! At the keyboard, you'll never reach my level of negative performance that I claim :-)))!
      Good luck
      crdlmnt7
    4. Hello,

      Great, by applying the Vaucluse adjustment, perfect!

      And how can we do if we want:

      - to compare only the values in columns A, C, and F

      - to exclude the null value from the comparison and highlight the lowest number different from 0?

      Thank you in advance!