A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

print sheet tabs names



 
 
Thread Tools Display Modes
  #1  
Old January 6th, 2004, 02:00 PM
JDM
external usenet poster
 
Posts: n/a
Default print sheet tabs names

Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets and
would like to print a list of the sheet tabs.
  #2  
Old January 6th, 2004, 02:20 PM
Paul B
external usenet poster
 
Posts: n/a
Default print sheet tabs names

JDM, here is one way

Sub List_All_Sheets()
'will list all worksheet names
'Click the first cell where you want to list your worksheet names
'and run this macro
Dim i As Integer
Dim ws As Worksheet
i = 0
For Each ws In ActiveWorkbook.Worksheets
With ActiveCell.Offset(i, 0)
..Value = ws.Name
End With
i = i + 1
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 97 & 2000
** remove news from my email address to reply by email **

"JDM" wrote in message
...
Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets and
would like to print a list of the sheet tabs.



  #3  
Old January 6th, 2004, 02:34 PM
Ron de Bruin
external usenet poster
 
Posts: n/a
Default print sheet tabs names

Or this one

It will add a sheet to your workbook and add the sheetnames
Then print and delete the sheet.

Sub PrintTabNames()
Application.ScreenUpdating = False
Dim Nsheet As Worksheet
Set Nsheet = Sheets.Add
Dim WS As Worksheet
Dim r As Integer
r = 1
For Each WS In Worksheets
If WS.Name Nsheet.Name Then
Nsheet.Range("A" & r) = WS.Name
r = r + 1
End If
Next WS
Nsheet.PrintOut
Application.DisplayAlerts = False
Nsheet.Delete
Application.DisplayAlerts = True
Application.ScreenUpdating = True
End Sub


--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)
www.rondebruin.nl



"Paul B" wrote in message ...
JDM, here is one way

Sub List_All_Sheets()
'will list all worksheet names
'Click the first cell where you want to list your worksheet names
'and run this macro
Dim i As Integer
Dim ws As Worksheet
i = 0
For Each ws In ActiveWorkbook.Worksheets
With ActiveCell.Offset(i, 0)
.Value = ws.Name
End With
i = i + 1
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 97 & 2000
** remove news from my email address to reply by email **

"JDM" wrote in message
...
Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets and
would like to print a list of the sheet tabs.





  #4  
Old January 6th, 2004, 02:41 PM
Arvi Laanemets
external usenet poster
 
Posts: n/a
Default print sheet tabs names

Hi

Here is an another way (I copied here my response to thread 'Listing all
worksheets', started by TimSwift at 23.12.2003 15:36)

Create an UDF
---
Public Function TabByIndex(TabIndex As Integer) As String
Application.Volatile
TabByIndex = Sheets(TabIndex).Name
End Function
---

Add a sheet SheetList. When you want all your sheets to be listed started
from cell A2, then:
A2=IF(ISERROR(TABBYINDEX(ROW(A1)));"";TABBYINDEX(R OW(A1)))
and copy the formula down as much as you do need.

--
(When sending e-mail, use address )
Arvi Laanemets



"JDM" wrote in message
...
Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets and
would like to print a list of the sheet tabs.



  #5  
Old January 6th, 2004, 02:46 PM
JDM
external usenet poster
 
Posts: n/a
Default print sheet tabs names

Paul B
Thanks for the reply, but when I run the macro listed, I
get a compile error at line "..Value = ws.Name" any
suggestions?
Thanks
-----Original Message-----
JDM, here is one way

Sub List_All_Sheets()
'will list all worksheet names
'Click the first cell where you want to list your

worksheet names
'and run this macro
Dim i As Integer
Dim ws As Worksheet
i = 0
For Each ws In ActiveWorkbook.Worksheets
With ActiveCell.Offset(i, 0)
..Value = ws.Name
End With
i = i + 1
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 97 & 2000
** remove news from my email address to reply by email **

"JDM" wrote in

message
...
Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets and
would like to print a list of the sheet tabs.



.

  #6  
Old January 6th, 2004, 02:51 PM
Chip Pearson
external usenet poster
 
Posts: n/a
Default print sheet tabs names

JDM,

There should be only a single period, not two, before the word
"Value".


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"JDM" wrote in message
...
Paul B
Thanks for the reply, but when I run the macro listed, I
get a compile error at line "..Value = ws.Name" any
suggestions?
Thanks
-----Original Message-----
JDM, here is one way

Sub List_All_Sheets()
'will list all worksheet names
'Click the first cell where you want to list your

worksheet names
'and run this macro
Dim i As Integer
Dim ws As Worksheet
i = 0
For Each ws In ActiveWorkbook.Worksheets
With ActiveCell.Offset(i, 0)
..Value = ws.Name
End With
i = i + 1
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 97 & 2000
** remove news from my email address to reply by email **

"JDM" wrote in

message
...
Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets and
would like to print a list of the sheet tabs.



.



  #7  
Old January 6th, 2004, 02:54 PM
Paul B
external usenet poster
 
Posts: n/a
Default print sheet tabs names

JDM, the line should only have one . like this, .Value = ws.Name, not
...Value = ws.Name, copy and paste the code and see if it works

--
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 97 & 2000
** remove news from my email address to reply by email **

"JDM" wrote in message
...
Paul B
Thanks for the reply, but when I run the macro listed, I
get a compile error at line "..Value = ws.Name" any
suggestions?
Thanks
-----Original Message-----
JDM, here is one way

Sub List_All_Sheets()
'will list all worksheet names
'Click the first cell where you want to list your

worksheet names
'and run this macro
Dim i As Integer
Dim ws As Worksheet
i = 0
For Each ws In ActiveWorkbook.Worksheets
With ActiveCell.Offset(i, 0)
..Value = ws.Name
End With
i = i + 1
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 97 & 2000
** remove news from my email address to reply by email **

"JDM" wrote in

message
...
Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets and
would like to print a list of the sheet tabs.



.



  #8  
Old January 6th, 2004, 04:45 PM
JDM
external usenet poster
 
Posts: n/a
Default print sheet tabs names

That worked perfectly. Thanks for the help
-----Original Message-----
JDM, the line should only have one . like this, .Value =

ws.Name, not
...Value = ws.Name, copy and paste the code and see if it

works

--
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 97 & 2000
** remove news from my email address to reply by email **

"JDM" wrote in

message
...
Paul B
Thanks for the reply, but when I run the macro listed, I
get a compile error at line "..Value = ws.Name" any
suggestions?
Thanks
-----Original Message-----
JDM, here is one way

Sub List_All_Sheets()
'will list all worksheet names
'Click the first cell where you want to list your

worksheet names
'and run this macro
Dim i As Integer
Dim ws As Worksheet
i = 0
For Each ws In ActiveWorkbook.Worksheets
With ActiveCell.Offset(i, 0)
..Value = ws.Name
End With
i = i + 1
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 97 & 2000
** remove news from my email address to reply by email

**

"JDM" wrote in

message
...
Is there a way to print a list of the sheet tabs in
Excel. I have a spreadsheet with hundreds of sheets

and
would like to print a list of the sheet tabs.


.



.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 07:08 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.