Sequencial Names On Worksheet Tabs

L

lehigh46

Hi All

I want to create a work book with 12 sheet tabs named from January to
December.
Is thee any way to name all 12 sheet tabs in one operation?


Thanks for your help.
 
M

Mike H

Hi,

Right click any sheet tab and paste this in and run it. Note ive included no
error trapping so if you don't have at least 12 sheets this fails

Sub name_Sheets()
For x = 1 To 12
Sheets(x).Name = MonthName(x)
Next
End Sub

Mike
 
L

lehigh46

Thanks Mike,
This works great.

Is there anything else that I could substitute for Month ie; Day?
I tried DayName(x) but that didn't work.
How abot years, starting with a predetermined year?
Or how about from a self created list like peoples names?

Thanks again for your help.
 
Top