Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Bob
iColor = 99 throws an error in 2003 Change to anything <57 and OK Gord On Sun, 25 Apr 2010 17:39:40 +0100, "Bob Phillips" wrote: TRy Private Sub Worksheet_Change(ByVal Target As Range) Dim icolor As Long Dim cell As Range If Not Intersect(Target, Range("B4:J33")) Is Nothing Then For Each cell In Target Select Case cell Case "Dan" icolor = 34 Case "John" icolor = 35 Case "Rose" icolor = 38 Case Else icolor = 99 End Select cell.Interior.ColorIndex = icolor Next cell End If End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel Macro for Coloring the cells | Excel Discussion (Misc queries) | |||
Conditional coloring of Excel cells, based on adjacent cell values? | Excel Worksheet Functions | |||
Problem while coloring cells in excel through vb | Excel Discussion (Misc queries) | |||
No shading or coloring of cells in excel. Is it windowXP setting? | Excel Discussion (Misc queries) | |||
COLORING IN CELLS | Excel Discussion (Misc queries) |