Link Worksheets to Master Sheet in Excel ๐Ÿ“Š

Learn how to connect all Excel sheets to a master sheet with VBA, creating a clickable Table of Contents for easy navigation.

Link Worksheets to Master Sheet in Excel ๐Ÿ“Š
Ajay Anand
6.2K views โ€ข Jun 25, 2023
Link Worksheets to Master Sheet in Excel ๐Ÿ“Š

About this video

The VBA program to create a 'Table of Contents' in Excel Workbooks is explained in this video.
Executing this program will add a new worksheet with hyperlinks to every Worksheet of the Workbook. So, this method is a perfect solution for linking every Worksheet of a Workbook to a Master sheet.

๐Ÿ‘‰ VBA Code for creating Table of Contents in Excel
Sub TableofContents()
Dim a As Worksheet, b As Worksheet
Dim c As Range, d As Integer
d = 1
Worksheets(1).Select
For Each b In Worksheets
If b.Name = "ToC" Then
Application.DisplayAlerts = False
Worksheets("Toc").Delete
Application.DisplayAlerts = True
End If
ActiveSheet.Buttons.Add(400, 75, 75, 25).Select
With Selection
.OnAction = "Temp"
.Characters.Text = "Master Sheet"
End With
ActiveSheet.Next.Select
On Error Resume Next
Next
Sheets.Add.Name = "ToC"
Range("C3").Select
ActiveCell.Offset(-1, -1).Value = "S No."
ActiveCell.Offset(-1, 0).Value = "Sheet Name"
For Each a In ActiveWorkbook.Worksheets
If ActiveSheet.Name NET a.Name Then
ActiveCell.Offset(0, -1).Value = d
ActiveCell.Hyperlinks.Add Anchor:=Selection, _
Address:="", SubAddress:="'" & a.Name & "'" & "!A1", _
TextToDisplay:=a.Name
ActiveCell.Offset(1, 0).Select
d = d + 1
End If
Next a
Columns("C:C").EntireColumn.AutoFit
End Sub
Sub Temp()
Sheets("ToC").Select
End Sub

๐Ÿ Top 25 Microsoft Word Tips and Tricks - https://youtu.be/l25Evu4ohKg
๐Ÿ“ 7 Most Important Tools in Excel - https://youtu.be/Pc88LGWNO70
๐ŸDownload my free eBook on Excel Macros - http://eepurl.com/gpT0RD
๐Ÿ‡Check these Books on Excel - https://xlncad.com/excel-resources/
๐Ÿ‰Read my articles on Excel - https://xlncad.com/

โ˜• If youโ€™ve found my videos helpful or enjoyable, consider supporting me with a coffee!
๐Ÿ‘‰ buymeacoffee.com/ajayanand

Subscribe to @XLnCADMalayalam for Excel, Word, PowerPoint, Access, Python and Power BI Tutorials in Malayalam.
https://www.youtube.com/c/XLnCADMalayalam

๐Ÿ“ข Disclaimer: If you click on my affiliates links, I am going to receive a tiny commission. The products that I advertise are the ones I believe in.
๐Ÿƒโ€โ™‚๏ธ My Running Kit for Hyderabad Marathon 2025
https://amzn.to/44IILeG
๐Ÿ“Š Think Like an Analyst: Books That Helped Me
https://amzn.to/3SNy6bi
๐Ÿ“š Mind-Opening Reads You Canโ€™t Miss
https://amzn.to/43tM2fu

#hyperlinkexcelsheet #excelvba #tableofcontents

Tags and Topics

Browse our collection to discover more content in these categories.

Video Information

Views

6.2K

Likes

105

Duration

4:05

Published

Jun 25, 2023

User Reviews

4.6
(1)
Rate:

Related Trending Topics

LIVE TRENDS

Related trending topics. Click any trend to explore more videos.

Trending Now