Conditional Formatting Cells Using Values From Adjacent Cells

GreenWizard

Board Regular
Joined
Dec 8, 2013
Messages
106
Is there a way to apply conditional formatting to one Column, but reference the Adjacent Column for the values (highest to lowest)? See example below:

COLUMN 1COLUMN 2
95
7310
488
705
421
297
995
5110
692
6410

<tbody>
</tbody>



















One can select Column 1 then click > 'Conditional Formatting' > 'Color Scales' > 'Green - Yellow - Red Color Scale'
And a color gradient will be applied to Column 1 where the highest value is Green and the lowest value is Red.

HOWEVER, how can you apply the same color gradient on Column 1, BUT reference Column 2 to determine the highest to lowest values??
In this example, values 73, 51, & 64 would get a Green background (highest value corresponding value = 10), while 42 would have a Red background (lowest value corresponding value = 1)???

Thanks in advance!!!
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce
in A1 put =B1=large($b$1$b$10,1)

if say b3 b5 b7 were all equal biggest then a3 a5 a7 would be colored
 
Upvote 0
I'm sorry, I don't understand. Can you clarify?

Is A1 the Column Name or the first Cell (Value = 9). Also where do I put that formula? Do I put that formula in the cell or perhaps a New Formatting Rule Description.

Thanks!!!
 
Upvote 0
it is the cond formatting formula applied to A1 (whose value =9)

I have excel 2000 so can only apply a max of 3 rules to a cell so in this example I would mark the highest and lowest
 
Upvote 0
@oldbrewer
The OP is referring to Colour Scales, which you don't have in your version.
@GreenWizard
I'm not sure it's possible to do what you are asking for. (But may well be proved wrong)
 
Upvote 0
Okay thank you!

If not, do you know a way to convert (via formula or conditional formatting) a value into an image instead of a color gradient? For example, setting a value to become a Green Star or a Blue Star or different type of shape, instead of shading the background of a cell?

Thanks again!!!
 
Upvote 0
you will likke this approach - Fluff.....

COLUMN 1COLUMN 2rankvlookuprank
9563614green
731014243pale green
48848320pale cyan
70563648cyan
42110355blue
29755636light yellow
99563676yellow
511014845light orange
692946946orange
641014103red
this macro has coloured the cells in column A
light yellow
green
cyan
light yellow
red
blue
light yellow
green
orange
green
Sub Macro4()
'
' Macro4 Macro
' Macro recorded 06/08/2018 by bob
'
'
For j = 2 To 11
Cells(j, 1).Select
With Selection.Interior
.ColorIndex = Cells(j, 8)
.Pattern = xlSolid
End With
Next j
End Sub

<colgroup><col><col><col span="11"><col><col span="2"></colgroup><tbody>
</tbody>
 
Upvote 0
Good stuff guys! Thank you very much for your help.

I'm still looking for a native solution that doesn't require a macro, but the link Fluff provided is extremely helpful as is the macro oldbrewer wrote. Thank you!!!!
 
Upvote 0

Forum statistics

Threads
1,215,506
Messages
6,125,193
Members
449,213
Latest member
Kirbito

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top