Share via

Renaming multiple tabs

Anonymous
2012-02-03T15:03:17+00:00

I have a workbook that was used in 2011, I've made a copy renaming it 2012.

All the tabs have Jan 2011, Feb 2011, Mar 2011 etc as the tab names. Is there a way of changing 2011 to 2012 in bulk?

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2012-02-03T15:25:26+00:00

Hi,

With code you can. Try this and if you change the suffix to 13 you can use it next year

Sub Rename_Tabs()

Dim x As Long, suffix As String

Dim v as Variant

suffix = " 12"

v = Split("Jan,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec", ",")

For x = 1 To Worksheets.Count

    If Not IsError(Application.Match(Left(Sheets(x).Name, 3), v, 0)) Then

    Sheets(x).Name = Left(Sheets(x).Name, 3) & suffix

    End If

Next

End Sub

Was this answer helpful?

0 comments No comments

5 additional answers

Sort by: Most helpful
  1. Anonymous
    2012-02-03T16:07:20+00:00

    You might also like to mark my response as answer.

    I did. Don't know why it's not showing...

    Just clicked on it again - THREE times and finally it's showing as answered.... ;-)

    Hi,

    Somethings going awry here today, 2 of my posts to others simply vanished.

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2012-02-03T15:59:06+00:00

    You might also like to mark my response as answer.

    I did. Don't know why it's not showing...

    Just clicked on it again - THREE times and finally it's showing as answered.... ;-)

    Was this answer helpful?

    0 comments No comments
  3. Anonymous
    2012-02-03T15:58:09+00:00

    Thanks very much.

    Spot on!

    You're welcome and thanks for the feedback. You might also like to mark my response as answer.

    Was this answer helpful?

    0 comments No comments
  4. Anonymous
    2012-02-03T15:37:17+00:00

    Thanks very much.

    Spot on!

    Was this answer helpful?

    0 comments No comments