Adding and naming Excel Worksheets

I need a macro that adds a new sheet in excel and uses a cell to name it. It should be possible to do this as many times as possible.
Who is Participating?
JiaHConnect With a Mentor Commented:
How about this one: (Add the new worksheet at the end of the worksheets and use the first one's A1 as the name, the better one is replace the 1 with it's name such as "Sheet1").

Sheets.Add(, After:=Worksheets(Worksheets.Count)).Name = Sheets(1).Range("A1").Value

Use this example as the basis of your macro:

Sub Add_Sheet()
    Sheets.Add().Name = Sheets(1).Range("A1").Value
End Sub
panikosAuthor Commented:
Returns an error "Object required". Also wouldn't this always look for sheet 1 rather than a sheet that has yet to be created.
Regarding panikos's comment: What the code does is add a sheet calling it the name you have put in sheet 1, cell A1. What version of Excel have you ?

Regarding JiaH's answer: Besides being a ripoff of my answer, if panikos had problems syntaxly with my example, I find it hard to believe panikos will have any luck with yours
All Courses

From novice to tech pro — start learning today.