Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I need to VBA the creation (and subsequent update) of a hyperlink to an external file in a shared workbook. The VBA gives me a runtime error. Any ideas on how to go around the apparent restriction? Note: The sharing cannot be turned off. If you could copy your response to my e-mail , I will appreciate it greatly. Thanks in advance, Luda |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
'shname : name of the sheet, range string
Call DynamicHyperLinks(ShName, "C156:C230") 'Here is the function for hyperlinks Sub DynamicHyperLinks(ShtName As String, Rng As String) Dim C1 Dim C Dim sh As Worksheet Dim LinkStr For Each C1 In Sheets(ShtName).Range(Rng) LinkStr = Split(C1, ".") C1.Value = LinkStr(0) 'checking file name & sheet name then creates link For Each sh In ActiveWorkbook.Sheets If sh.Name = LinkStr(0) Then Set C = Sheets(ShtName).Range(Rng).Find (What:=sh.Name, LookAt:=xlWhole) ActiveSheet.HyperLinks.Add Anchor:=C, Address:="", SubAddress:="'" & sh.Name & "'!A1", ScreenTip:="Click On Links" End If Next Next Set sh = Nothing End Sub -----Original Message----- Hi, I need to VBA the creation (and subsequent update) of a hyperlink to an external file in a shared workbook. The VBA gives me a runtime error. Any ideas on how to go around the apparent restriction? Note: The sharing cannot be turned off. If you could copy your response to my e-mail , I will appreciate it greatly. Thanks in advance, Luda . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Hyperlink problem. | Excel Discussion (Misc queries) | |||
Hyperlink Problem | Excel Worksheet Functions | |||
Hyperlink Problem | Links and Linking in Excel | |||
Hyperlink problem | Excel Worksheet Functions | |||
Problem with hyperlink | Excel Discussion (Misc queries) |