This documentation is archived and is not being maintained.
Worksheet.Name Property (Excel)
Returns or sets a String value that represents the object name.
The following code example sets the name of the active worksheet equal to today's date.
' This macro sets today's date as the name for the current sheet Sub NameWorksheetByDate() Range("D5").Select Selection.Formula = "=text(now(),""mmm dd yyyy"")" Selection.Copy Selection.PasteSpecial Paste:=xlValues Application.CutCopyMode = False Selection.Columns.AutoFit ActiveSheet.Name = Range("D5").Value Range("D5").Value = "" End Sub