How to use macro to rename worksheet with date +"text"

S

Sherri

What context must I use to rename a worksheet tab with the the current date

I have success with naming it in a macro with text using
ActiveSheet.Selec
ActiveSheet.Name = "HD

I would like tab to be named "Date-HD" but the TODAY() function doesn't work.....

Thanks for your input
 
B

Bob Phillips

Activesheet.Name = Format(Date, "yyyy mm dd") & "-HD"

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
S

Sherri

hi Frank

I tweaked to

ActiveSheet.Name = Format(Date, "mm-dd-yy") & "-HD

and it does what I wanted

Thanks for the help

Sherri
 
Top