How can I list as hyperlinks a list of worksheet names in Excel?
I have one excel file with multiple worksheets (200+). I find the worksheet I need by scrolling through them. Can I somehow list as hyperlinks all the worksheet names on one page? This way I can quickly click on the desired name, and it opens that worksheet.
Public Comments
- Here is a way to create 'hyperlinks' to the various sheets, without having to manually create one for each sheet. This example assumes the sheet to contain the 'master list' of all sheet names is "Sheet1". Select Sheet1 as the active worksheet. Copy the following event handler to the clipboard: Private Sub Workbook_SheetBeforeDoubleClick(ByVal Sh As Object, _ ByVal Target As Range, Cancel As Boolean) Sheets("Sheet1").Select End Sub Press ALT + F11 Double click 'This Workbook' in the Microsoft Excel Objects in the upper left quadrant. Paste the event handler into the editing area to the right. In the menus at the top of the VBE, select INSERT > MODULE Copy the following macro and paste it into the newly created module: Sub CreateLinks() Dim ws As Worksheet For Each ws In Sheets If ws.Name <> "Sheet1" Then ActiveSheet.Range("A" & Rows.Count).End(xlUp).Offset(1).Value = ws.Name End If Next End Sub In the menus at the top, go to Tools > Macros, select the CreateLinks macro, and click 'RUN'. Double click on 'Sheet1' in the Microsoft Excel Objects in the upper left quadrant. Copy and paste the following event handler into the Sheet1 editing area to the right: Private Sub Worksheet_SelectionChange(ByVal Target As Range) On Error Resume Next If Target.Column = 1 Then Sheets(ActiveCell.Value).Select End If End Sub Close the VBE and return to Sheet1. You will see a complete list of all worksheet names in column A. To activate any sheet, simply click the sheet name. To return to the 'master sheet' form ANY sheet in the workbook, simply double click any cell. Note: this can also be modified to 'toggle' between any two sheets in the workbook, if you wanted to compare them. ======= Edit: if you wish to insert a new sheet, say 'Master', and use that as a dashboard, simply change the two "Sheet1" references above to "Master". Make sure that the 'Master' sheet is the active sheet prior to following the above procedure.
Powered by Yahoo! Answers