Extending conditional formatting

FergusonRK

New Member
Joined
Jul 26, 2007
Messages
14
Hi Folks,

Excel Newbie needs to know if there is a way to do conditional formatting on more than three data elements... Excel only provides the capability to select three elements, can this be increased by some configuration setting within Excel or by script?

Thanks much,

Fergie
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.

Gerald Higgins

Well-known Member
Joined
Mar 26, 2007
Messages
9,258
You can get it to four by using the default format.

If you only want text colours, you can get a fifth by using custom formats

Otherwise, I think you'll need VBA.
 

ADAMC

Well-known Member
Joined
Mar 20, 2007
Messages
1,169
Office Version
  1. 2013
Platform
  1. Windows
Not sure if this helps but its something i use:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Value <= 10 Then Target.Interior.ColorIndex = 1
If Target.Value > 10 And Target.Value <= 20 Then Target.Interior.ColorIndex = 3
If Target.Value > 20 And Target.Value <= 30 Then Target.Interior.ColorIndex = 4
If Target.Value > 30 And Target.Value <= 40 Then Target.Interior.ColorIndex = 5
If Target.Value > 40 And Target.Value <= 50 Then Target.Interior.ColorIndex = 6
If Target.Value > 50 And Target.Value <= 60 Then Target.Interior.ColorIndex = 7
End Sub

I have 5 conditions but i imagine you could add as many as required.
 

Forum statistics

Threads
1,181,659
Messages
5,931,273
Members
436,786
Latest member
Deniel

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
Top