List of sheets.

  • Thread starter Thread starter Taylor Francis
  • Start date Start date
T

Taylor Francis

Is there a way to generate a list of all the worksheet names on one
sheet of a book?
Taylor
 
Hi Taylor

Try this

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 ThisWorkbook.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
 
Back
Top