using a horizontal list entitled "Training2019" with hyperlinks to 3 hidden worksheets using code:
Private Sub Worksheet_FollowHyperlink (ByVal Target As Hyperlink)
LinkTo = Target.SubAddress
WhereBang = InStr(1, LinkTo, "!")
If WhereBang > 0 Then
MySheet = Left(LinkTo, WhereBang-1)
Worksheets (MySheet).Visibe = True **ERROR Here
Worksheets (MySheet).Select
MyAddr = Mid(LinkTo, WhereBang + 1)
Worksheets(mySheet).Rang(MyAddr).Select
EndIf
End Sub
each sheet also has the following code:
Private Sub Worksheet_FollowHyperlink(ByVal Tareget A Hyperlink)
Worksheets ("Training2019").Select
Target.Parent.Worksheet.Visible = False
End Sub
what am I doing wrong?
Private Sub Worksheet_FollowHyperlink (ByVal Target As Hyperlink)
LinkTo = Target.SubAddress
WhereBang = InStr(1, LinkTo, "!")
If WhereBang > 0 Then
MySheet = Left(LinkTo, WhereBang-1)
Worksheets (MySheet).Visibe = True **ERROR Here
Worksheets (MySheet).Select
MyAddr = Mid(LinkTo, WhereBang + 1)
Worksheets(mySheet).Rang(MyAddr).Select
EndIf
End Sub
each sheet also has the following code:
Private Sub Worksheet_FollowHyperlink(ByVal Tareget A Hyperlink)
Worksheets ("Training2019").Select
Target.Parent.Worksheet.Visible = False
End Sub
what am I doing wrong?
Last edited: