View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
ShaneDevenshire ShaneDevenshire is offline
external usenet poster
 
Posts: 2,344
Default Hard code date in excel . . .

Hi,

If all you need is to display the current year and prior month:
=EDATE(TODAY(),-1) displays the prior month when you format it to MMMM
(you don't need the TEXT function, just use Format, Cells, Number tab, Custom
=TODAY() just format this to the custom format YYYY same as above, don't
need the TEXT function although both of these can be used with the text
function.

EDATE is part of the Analysis ToolPak in 2003 and earlier, so you might have
to attach it by choosing Tools, Add-ins, and checking it.
--
Thanks,
Shane Devenshire


"Rachel Costanza" wrote:

I have a an excel workbook with 15 worksheets that I have to update the prior
month and current year on every month to produce a turnover report. Can I
use VB or a DATE function to do this?

I have tried =TEXT(TODAY(),"mmmm") but that only gives me the current month
and not the year. I need the prior month and current year.

Any help is appreciated!

Best,

Rachel Costanza