View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Stilla
 
Posts: n/a
Default Tab-naming macro only works once :-(

Hi.. thanks to you guys, I learned to name tabs with a macro. I changed some
information on some worksheets, and tried to run the macro again to adjust
tab names... but nothing happened. What's wrong?

This is the macro I'm using (aa3 is the cell in each sheet that contains the
name):

Sub TABNAMING()
Dim i As Integer
On Error Resume Next
For i = 1 To Sheets.Count
Sheets(i).Name = Sheets(i).Range("aa3").Value
Next i
On Error GoTo 0
End Sub