Sheet

  • Thread starter Thread starter Jim
  • Start date Start date
J

Jim

How would I wrtie a macro the would creat in a workshhet a list of the
names of all the other worksheets in a workbook
 
Sub CreateSummarySheet()
Dim sht As Object
Dim N As Long
N = 1
For Each sht In Sheets
Cells(N, 1).Value = sht.Name
N = N + 1
Next
End Sub
'--
Or use the free Excel add-in "XL Extras" at...
http://www.realezsites.com/bus/primitivesoftware
No registration required.
--
Jim Cone
San Francisco, USA


<[email protected]>
wrote in message
How would I wrtie a macro the would create in a workshhet a list of the
names of all the other worksheets in a workbook
 
try

Sub listsheets()
For i = 1 To Worksheets.Count
Cells(i, "a") = Sheets(i).Name
Next i
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top