Seperating hyperlink address from viewable text
Try this UDF:
Function hyp(r As Range) As String
hyp = ""
If r.Hyperlinks.Count 0 Then
hyp = r.Hyperlinks(1).Address
Exit Function
End If
If r.HasFormula Then
rf = r.Formula
dq = Chr(34)
If InStr(rf, dq) = 0 Then
Else
hyp = Split(r.Formula, dq)(1)
End If
End If
End Function
So if A1 contains the e-mail hyperlink, then:
=hyp(A1) will display the mailto: address.
--
Gary''s Student - gsnu200801
"Aominay" wrote:
I have a list of 551 hyperlinked email addresses. Column A shows the persons
name, and the name is hyperlinked with the persons email address. I would
like to figure out how to keep the person's name in Column A, and be able to
view the email address as text in another column without having to type each
one out individually (or go through each one and copy and paste from the Edit
Hyperlink box). Is there a way to do this in MS Excel 2003 quickly?
|