E-Mail Hyperlinks in Excel

R

Ray

If an e-mail address is entered in a cell, Excel
automatically creates a hyperlink. How can this automatic
hyperlink creation feature be disabled?

(After entry, the hyperlink can be deleted, but I do not
want it created in the first place.)

Thanks for any help.
 
A

Andy B

Ray

You will lose the hyperlink if you copy a General formatted cell and use
Format Painter to reformat. This means you could do a column at a time.

Andy.
 
D

Dave Peterson

You could use a userdefined function that extracts the link/email address:

Option Explicit
Function GetLink(Rng As Range) As String
Application.Volatile

Set Rng = Rng(1)

If Rng.Hyperlinks.Count = 0 Then
GetLink = ""
Else
GetLink = Rng.Hyperlinks(1).Address
End If
End Function

So if cell A1 contained a link to mailto:[email protected]
then =getlink(a1) would return this: mailto:[email protected]

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

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top