Prior Month

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How do I get the prior month to automatically conditionally format when the
current month rolls around?
I have this formula in Formula Is =MONTH(M$4)=MONTH(TODAY()). That
highlights November. I need to highlight October instead, and when December
rolls around, November will be highlighted.

Thanks,
 
Perhaps

=MONTH(M$4)=MONTH(TODAY())-1

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Howard,

Could you explain in a bit more detail then, data and expected results, as
that was a bit of a guess on the information provided so far.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Bob,
Columns D4 thru O4 have the month-end, Jan thru Dec. Then each cell in a
column below the date has various stock market data (numbers). So, most of
the October data would not be populated until November 1, using October
closing prices. I want to highlight the column for the October month (M4)
now. When December rolls around and I populate the data for November, I want
the highlight to roll forward to November.
Sorry for the delay. I left work and went home, although maybe my real home
is at work?!
Thanks,
 
Howard,

We probably have tome zone differences making it more difficult as well.

I just tried my formula with the data as described, and M4 highlighted
correctly.

The only thing I can think is that you are applying CF to many cells, say
D4:O4 (Jan-Dec 2005), If you applied my formula exactly as supplied, D4 will
highlight. It needs to be adjusted to the start of the data, i.e D4, so the
formula to enter is actually
=MONTH(D$4)=MONTH(TODAY())-1
Excel will take care of updating it relatively.

You could of course also apply it to more rows than just 4.

Any better?


--

HTH

RP
(remove nothere from the email address if mailing direct)
 
Bob,

It's working. You said, "It needs to be adjusted to the start of the data,
i.e. D4..."
That was the key.

Thanks for your help!
 
Back
Top