Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default rename sheet tabs in excel

I have a workboo that contains 13 worksheets, I want to rename all sheets
beginning with Mar 07, April 07 etc. I have forgotten how to do this without
renaming individually. Can anyone help? Thanks
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default rename sheet tabs in excel

You could use a macro:

Option Explicit
Sub testme()
Dim wCtr As Long
For wCtr = 1 To Worksheets.Count
Worksheets(wCtr).Name = Format(DateSerial(2007, wCtr + 2, 1), "mmmm-yy")
Next wCtr
End Sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

blantyreson wrote:

I have a workboo that contains 13 worksheets, I want to rename all sheets
beginning with Mar 07, April 07 etc. I have forgotten how to do this without
renaming individually. Can anyone help? Thanks


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 903
Default rename sheet tabs in excel

Minor change I would suggest that when naming worksheets or files
that are based on a date that you put the year before the month and
day so that they can be sorted or appear in a directory in order.
"yyyy-mm" instead of "mmmm-yy"

A macro to sort worksheets by their name SortALLSheets in
http://www.mvps.org/dmcritchie/excel...#sortallsheets
--
HTH,
David McRitchie, Microsoft MVP -- Excel
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm


"Dave Peterson" wrote in message
...
You could use a macro:

Option Explicit
Sub testme()
Dim wCtr As Long
For wCtr = 1 To Worksheets.Count
Worksheets(wCtr).Name = Format(DateSerial(2007, wCtr + 2, 1),
"mmmm-yy")
Next wCtr
End Sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

blantyreson wrote:

I have a workboo that contains 13 worksheets, I want to rename all sheets
beginning with Mar 07, April 07 etc. I have forgotten how to do this
without
renaming individually. Can anyone help? Thanks


--

Dave Peterson


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
rename tabs May Excel Discussion (Misc queries) 5 February 14th 07 11:45 PM
Rename all existing worksheet tabs MikeM Excel Discussion (Misc queries) 14 October 20th 06 03:29 AM
How to rename Excel Sheet with more characters? Billy316 Excel Discussion (Misc queries) 4 July 20th 05 05:11 AM
I cannot rename my excel sheet? Cissy Excel Worksheet Functions 1 April 3rd 05 05:50 AM
RENAME SHEET TABS AOYUMATICALLY RENAME SHEET TAB NAMES VIA MACRO'S Excel Discussion (Misc queries) 3 February 3rd 05 01:06 PM


All times are GMT +1. The time now is 08:53 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"