Enable hyperlinks

  • Thread starter Thread starter Thermometer
  • Start date Start date
T

Thermometer

I have an Excel file with about 200 URLs that have been imported. They
show up as plain text. I can click on each one, choose "Hyperlink,"
and activate each one individually. Any way to do them all at once?

Ralph
 
Format one as a hyperlink. Click on your format painter in the toolbar and
paint the formatting over the rest. It should work.
Pat
 
Hi

You may need to adjust the code to suit your needs....

Sub test()
Dim c As Range
With ActiveSheet
For Each c In Selection
If Left(c, 4) = "www." Then
c.Hyperlinks.Add Anchor:=c, Address:="http://" & c.Text
ElseIf Left(c, 7) = "http://" Then
c.Hyperlinks.Add Anchor:=c, Address:=c.Text
End If
Next c
End With
End Sub
--

XL2003
Regards

William
(e-mail address removed)
 
'/===============================/
Sub MakeHyperlinks()
'make hyperlinks out of selected cells if possible
Dim rngCell As Range
Dim varAnswer As Variant

On Error Resume Next

For Each rngCell In Selection
ActiveSheet.Hyperlinks.Add Anchor:=rngCell, _
Address:=rngCell.Value _
, TextToDisplay:=rngCell.Value
Next rngCell

End Sub
'/===============================/

HTH,
 

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

Back
Top