Hi
How do I write code to insert a list of hyperlinks on sheet1 of my workbook, linking to all other sheets when clicked
I have got this code
Sub Macro3()
rw = 1
For Each sh In Sheets
rw = rw + 1
Cells(rw, 1).Select
If sh.Name <> "Sheet1" Then
ActiveSheet.Hyperlinks.Add Anchor:=Cells(rw, 1), Address:="", SubAddress:= _
sh.Name & "!A1", TextToDisplay:=sh.Name
End If
Next sh
End Sub
When clicked I get the error "Reference is not valid"
Can anyone help....
How do I write code to insert a list of hyperlinks on sheet1 of my workbook, linking to all other sheets when clicked
I have got this code
Sub Macro3()
rw = 1
For Each sh In Sheets
rw = rw + 1
Cells(rw, 1).Select
If sh.Name <> "Sheet1" Then
ActiveSheet.Hyperlinks.Add Anchor:=Cells(rw, 1), Address:="", SubAddress:= _
sh.Name & "!A1", TextToDisplay:=sh.Name
End If
Next sh
End Sub
When clicked I get the error "Reference is not valid"
Can anyone help....