How to make an HTML link in excel

J

JoeStL

I want to link a few sites to some cells in excel. I would like place
link within specific text.
Ex. _Link_name (\"http://www.google.com\")_ and hav
the URL hidden. Link example goes to Google.com.
Thank you,
Jo
 
D

Dave Peterson

I'm not sure you can hide the tooltip that shows up when you let the mouse hover
over the cell.

Maybe you could add a shape to the worksheet and then assign a macro to that
shape. The macro could follow the hyperlink.

For instance, I added a couple of rectangles to a worksheet and assigned the
same macro to both of them:

Option Explicit
Sub myLink()

Dim myHyperLink As String

myHyperLink = ""
Select Case LCase(Application.Caller)
Case Is = "rectangle 3": myHyperLink = "http://www.google.com"
Case Is = "rectangle 4": myHyperLink = "http://www.microsoft.com"
End Select

If myHyperLink = "" Then
Beep
Else
ThisWorkbook.FollowHyperlink Address:=myHyperLink, NewWindow:=True
End If

End Sub


If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm
 
Top