Conditional Formatting - Color row based on one cell value

M

Monica

I need to color code a row (10 columns) based on the value in column a being
a specific job name or number (8 to choose from). Conditional formatting
only allowed 3 conditions and only worked on individual cells.
 
G

GerardV

For more than 3 formats I use somthing like:

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Select Case Cells(1.1).Value
Case 1
Range("A1:J1").Interior.ColorIndex = 35
Range("A1:J1").Font.Bold = False
Case "Gerard"
Range("A1:J1").Interior.Color = RGB(255, 0, 0)
Range("A1:J1").Font.Bold = True
Case Else
Range("A1:J1").Interior.Color = RGB(255, 255, 255)
Range("A1:J1").Font.Bold = False
End Select

End Sub
 

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