View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default If any cell in named range = 8 then shade named range

if application.countif(Range("Block_Three"),8) 0 then
Range("Block_Three").Interior.ColorIndex = 6
End if


or if only exactly 1
if application.countif(Range("Block_Three"),8) = 1 then
Range("Block_Three").Interior.ColorIndex = 6
End if

--
Regards,
Tom Ogilvy



"JJ" wrote in message
...
How would I do this please?

If any one of the cells in the range("Block_Three") = 8 then shade the
range("Block_Three") yellow.