Hyperlink Macro Issue

jdutle

New member
Joined
Dec 9, 2015
Messages
8
Reaction score
0
Points
0
I am very new to marcos and am having trouble.

As part of a macro I was working on, I wanted to open the hyperlink of a selected cell (contains link to another workbook.)

When I run the macro it gives me the usual warning to make sure the link is from a trustworthy source, and asks if Id like to open the file. I click ok, then the hourglass comes up for a few seconds and then it goes away. Nothing happens though, the file does not open.

But, If I click the actual cell that contains the hyperlink, it gives me the warning, I click ok, and then the file opens. Its frustrating that it worked before I saved and closed it.

I created the code using the Macro Recorder. While recording, when I click on the cell with the hyperlink it will open, but not after Ive finished and tried to run the macro. Please help.

Sub Macro1()
'
' Macro1 Macro
Range("B7").Select
Selection.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
End Sub​
 
Back
Top