View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Patrick Molloy Patrick Molloy is offline
external usenet poster
 
Posts: 1,049
Default Change the color of a range of cells.


you can do this easily with Conditional Formatting

or in code, something akin to this:-
If Range("A5")=somevalue then range("A1:A5").Interior.Colorindex =
somecolorcode
where you put appropriate values in for somevalue and somecolorcode

"Srajes" wrote in message
...
Hi,

I need to change the color of a range of cells depending up on the value
in
another cell.
Consider cells
1 2 3 4 5
, I need to change the color of all thse 5 cells depending up on the value
in cell 5.

Thanks in advance for your help.
SR