How can I make a content (sumary) of a workbook

A

Adrian Ficker

I want that in firs worksheet from a workbook to add links to all the sheets
that are in that workbook. Something like indexing of the workbook. Like a
site map.
So when i want to see the a specific sheet to navigate jusc clicking the
link that is having.
 
B

bgeier

Try


Sub CreateIndex()
Dim intPlaceRow As Integer
Dim intSheetCounter As Integer

intPlaceRow = 1
For intSheetCounter = 1 To Worksheets.Count
ThisWorkbook.Worksheets("Sheet4").Cells(intPlaceRow, 1) =
Worksheets(intSheetCounter).Name
Cells(intPlaceRow, 1).Select
ActiveSheet.Hyperlinks.Add Anchor:=Selection, Address:="",
SubAddress:=ThisWorkbook.Worksheets("Sheet4").Cells(intPlaceRow,
1).Value & "!A1",
TextToDisplay:=ThisWorkbook.Worksheets("Sheet4").Cells(intPlaceRow,
1).Value
intPlaceRow = intPlaceRow + 1
Next
End Sub
 
Top