Hyperlink in Excel || Basic to Adv || VBA Code

Hyperlink in Excel || Basic to Adv || VBA Code

Hyperlink in Excel || Basic to Adv || VBA Code

VBA Code :-

Sub CreateLinksToAllSheets()
Dim sh As Worksheet
Dim cell As Range
For Each sh In ActiveWorkbook.Worksheets
If ActiveSheet.Name <> sh.Name Then
ActiveCell.Hyperlinks.Add Anchor:=Selection, Address:=””, SubAddress:= _
“‘” & sh.Name & “‘” & “!A1”, TextToDisplay:=sh.Name
ActiveCell.Offset(1, 0).Select
End If
Next sh
End Sub

durgaprasad

leave a comment

Create Account



Log In Your Account