Evening all
I have 8 existing worksheets and I would like to add another 61, emp1:emp61. I have created a list on a worksheet highlighted it and then run the following code
Code: Select all
Sub NameTabs()
Dim N As Integer
On Error Resume Next
For Each x In Selection
N = N + 1
Sheets(N).Name = x
Next
End Sub
But all that is happening is the 8 existing tabs are renamed emp1:emp8. Any examples please of how to add the new sheets and rename them as required?
Steve
http://www.freightpro-uk.com" onclick="window.open(this.href);return false;
“Tell me and I forget, teach me and I may remember, involve me and I learn.”
― Benjamin Franklin