Colour cells in columns i & u to ae, based on c & i

outlook

Board Regular
Joined
Jun 16, 2010
Messages
93
Hi,

I wonder if someone can help me as I'm tearing my hair out ...

I need to colour the cells in columns I, and U to AE. The colour depends on what text is found in C and I.

For example ...

If C6 = "LAND" and I6 = "Intro", I6 & V6 needs to be coloured brown.

Can this be done, or am I just asking too much? I've tried conditional formatting but it doesn't allow enough varients.

Thank you.
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
I am using 11 colours between column U & AE.

I am using a minum of 2 conditions per colour.

I hope this answers your question, as it's difficult to explain.
 
Upvote 0
Okay, can you define your conditions for me and what colors each condition would be?
 
Upvote 0
"I" contains "Refund" but not included in any other conditions below = Pink

"C" contains "LAND" and "I" contains "Intro" = Brown

"C" contains "LAND" and "I" contains "Homelet Charge" = Red

"C" contains "LAND" and "I" contains "Management" or "Monthly Fee" = Orange

"C" contains "LAND" and "I" contains "Continuation" = Yellow

"C" contains "LAND" and "I" contains any other text not included in "LAND" catagories above = Light Green

"C" contains "TENC" and "I" contains "Admin" or "Contract" = Dark Green

"C" contains "TENC" and "I" contains "Continuation" or "Card Handling" = Light Blue

"C" contains "CONT" and "I" contains "Commission" or "Hallmark" = Bright Blue

"I" contains any other conditions not covered in any of the above = Navy Blue
 
Upvote 0
What version of Excel do you run? If you are running 2003 or older, only 56 colors are available. If you want to see a list of colors that are available in those versions run this macro first on an empty worksheet and then post back.

Code:
Sub colors56()
    Application.ScreenUpdating = False
    
    Dim i As Long
    
    For i = 0 To 56
        Cells(i + 1, 1).Interior.ColorIndex = i
    Next i
    
    Application.ScreenUpdating = True
End Sub
 
Upvote 0
Hi,

I'm running 2007, and by running the macro you gave me, I get 56 colours back.

Thanks.
 
Upvote 0

Forum statistics

Threads
1,214,534
Messages
6,120,086
Members
448,944
Latest member
sharmarick

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