View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
Ken Johnson Ken Johnson is offline
external usenet poster
 
Posts: 1,073
Default Conditional formatting - different cell colour for each year following from user input date?

Hi StargateFan and Jason,

That's exactly what I meant, I just wasn't sure which cell address to
include in the Mod function.
You can also squeeze in one more color by starting off with an ordinary
fill color with no condition eg yellow, then instead of using
=mod($A$1,3) = 0 then 1 then 2 in each subsequent cond format, use
=mod($A$1,4) = 1 then 2 then 3 in each subsequent cond format. This
way, when mod($A$1,4) = 0 (eg 2008,2012 etc) the cell fill color
defaults to the original fill color before cond format was applied
(yellow) or if you didn't apply one it defaults to no fill, still a
fourth color.

Ken Johnson