![]() |
How can Excel create a list of tabs on a worksheet?
I have a large document with constantly changing tabs. I would like to
create a document at the front with the tab names. Is there a way to do this automatically? Or would it be quicker to just type them in? |
Alice, here is one way,
Sub Sheet_Names() Dim ws As Worksheet With Worksheets.Add .Name = "Sheet Names" .Move befo=Worksheets(1) End With Sheets("Sheet Names").Activate Range("a1").Activate For Each ws In Worksheets If ws.Name < "Sheet Names" Then ActiveCell.Formula = ws.Name ActiveCell.Offset(1, 0).Select End If Next End Sub -- Paul B Always backup your data before trying something new Please post any response to the newsgroups so others can benefit from it Feedback on answers is always appreciated! Using Excel 2002 & 2003 "AliceNXLand" wrote in message ... I have a large document with constantly changing tabs. I would like to create a document at the front with the tab names. Is there a way to do this automatically? Or would it be quicker to just type them in? |
Thanks, Paul, I still need help with where to paste this information. I'm
not really familiar with macros. I understand the concept, but, haven't practiced much. If this will take too long on the forum, please e-mail me. Thanks, VERY MUCH. "Paul B" wrote: Alice, here is one way, Sub Sheet_Names() Dim ws As Worksheet With Worksheets.Add .Name = "Sheet Names" .Move befo=Worksheets(1) End With Sheets("Sheet Names").Activate Range("a1").Activate For Each ws In Worksheets If ws.Name < "Sheet Names" Then ActiveCell.Formula = ws.Name ActiveCell.Offset(1, 0).Select End If Next End Sub -- Paul B Always backup your data before trying something new Please post any response to the newsgroups so others can benefit from it Feedback on answers is always appreciated! Using Excel 2002 & 2003 "AliceNXLand" wrote in message ... I have a large document with constantly changing tabs. I would like to create a document at the front with the tab names. Is there a way to do this automatically? Or would it be quicker to just type them in? |
Thanks Paul! I got it to work. It's great. Now I can use this one to build
on for other stuff I need. Forget the last message. "AliceNXLand" wrote: Thanks, Paul, I still need help with where to paste this information. I'm not really familiar with macros. I understand the concept, but, haven't practiced much. If this will take too long on the forum, please e-mail me. Thanks, VERY MUCH. "Paul B" wrote: Alice, here is one way, Sub Sheet_Names() Dim ws As Worksheet With Worksheets.Add .Name = "Sheet Names" .Move befo=Worksheets(1) End With Sheets("Sheet Names").Activate Range("a1").Activate For Each ws In Worksheets If ws.Name < "Sheet Names" Then ActiveCell.Formula = ws.Name ActiveCell.Offset(1, 0).Select End If Next End Sub -- Paul B Always backup your data before trying something new Please post any response to the newsgroups so others can benefit from it Feedback on answers is always appreciated! Using Excel 2002 & 2003 "AliceNXLand" wrote in message ... I have a large document with constantly changing tabs. I would like to create a document at the front with the tab names. Is there a way to do this automatically? Or would it be quicker to just type them in? |
All times are GMT +1. The time now is 08:04 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com