![]() |
Rename worksheets with VBA
Hi all, Was hoping someone could give me a tip with renaming worksheets. I have around 80 worksheets to record data. I also have anothe worksheet, which has a vertical list of names. I would like Excel to rename all of the worksheets, according t whatever the list is made up of. ie. Worksheet 1 name = List A1, Worksheet 2 name = List A2 etc. This is a once off task - so I can rename them all individually i needed, but just wandering if there is an easy way to do this? Thanks Ro -- system ----------------------------------------------------------------------- systemx's Profile: http://www.excelforum.com/member.php...fo&userid=2925 View this thread: http://www.excelforum.com/showthread.php?threadid=52341 |
Rename worksheets with VBA
don't know if i have enough info from you , but if the sheet with the names is
named list, drag it si it's the last sheet then this may do what you want Option Explicit Dim i As Long Sub rename_sheets() For i = 1 To Worksheets.Count - 1 Worksheets(i).Name = Sheets("list").Range("A" & i).Value Next End Sub -- Gary "systemx" wrote in message ... Hi all, Was hoping someone could give me a tip with renaming worksheets. I have around 80 worksheets to record data. I also have another worksheet, which has a vertical list of names. I would like Excel to rename all of the worksheets, according to whatever the list is made up of. ie. Worksheet 1 name = List A1, Worksheet 2 name = List A2 etc. This is a once off task - so I can rename them all individually if needed, but just wandering if there is an easy way to do this? Thanks Rob -- systemx ------------------------------------------------------------------------ systemx's Profile: http://www.excelforum.com/member.php...o&userid=29254 View this thread: http://www.excelforum.com/showthread...hreadid=523414 |
All times are GMT +1. The time now is 10:30 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com