conditional formatting

G

Guest

i have an excel sheet with various numbers. I am looking to conditionally
format each cell based on the cell beneath it... i.e. if you have in the A
column A1=23 A2=32 A3=12 A4=12 A5=11... i am trying to get excel to evaluate
cell a1 is less than a2 thus a1 would be shaded red. A2 is greater than a3
and thus shaded green. a3 and a4 are equal, thus shaded yellow and so on... i
would like to apply this formatting using a relative reference of each cell
evaluating against A(Row# + 1)... how do i do this?
 
E

ElsiePOA

Highlight column A and select "Conditional formatting" For condition
choose "cell is" - "less than" and enter =A2. Then select the forma
you want for red shading.
Then add condition 2 and 3 with "greater than" formatted green an
"equal to" formatted yellow.

All of your cells in column A should now have the right colo
formatting. Of course, the last cell in the column will be formatte
green because the cell benith it is blank.
:cool
 
D

Dave Peterson

That "and so on" is scarry.

Excel's conditional formatting only allows for 3 conditions (plus the default
formatting).

But if you select all your range A1:whatever with the activecell being A1, you
can write the formula for the activecell and excel will adjust it for the others
in the selection.

If you get it to work in one location, you can copy|paste special|formats
(the CF formatting gets copied as well as the normal formatting.)
 
G

Guest

not working... unfortunately i think i've not communicated clearly.
Each cell to use the exact same conditions
see example:
column
rows A
1 27.50 <-- red, because is less than A2
2 28.02 <-- green, because is greater than A3
3 27.65 <-- green, because is greater than A4
4 27.50 <-- Yellow, because is equal to A5
5 27.50 <-- green, because is greater than A6
6 26.78 <-- red, because is greater than A7
7 27.32 <-- color will be based on the value of A8
and so on... for possibly 2-3 thousand lines...
we're looking to use this to identify trends in historical market data.
 
G

Guest

Each cell to use the exact same conditions

EXAMPLE BELOW

column
rows A
1 27.50 <-- red, because is less than A2
2 28.02 <-- green, because is greater than A3
3 27.65 <-- green, because is greater than A4
4 27.50 <-- Yellow, because is equal to A5
5 27.50 <-- green, because is greater than A6
6 26.78 <-- red, because is greater than A7
7 27.32 <-- color will be based on the value of A8
and so on... for possibly 2-3 thousand lines...
we're looking to use this to identify trends in historical market data.
 
G

Guest

THANKS A TON...
my first try with your directions failed because i mistakenly SELECTED
$A$2... but you meant to TYPE in A2...

you're great!
have a great day
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top