URL ADDRESS TO HYPER LINK

alan myers

Board Regular
Joined
Oct 31, 2017
Messages
119
Office Version
  1. 365
Platform
  1. Windows
I HAVE A LIST OF URLS AND WANT TO CONVERT TO HYPER LINKS THIS IS MY MACRO I RECORDED
BUT I WANT TO START AT A1 AND GO TO THE LAST CELL OF URLS


Sub HYPERFIX()
'
' HYPERFIX Macro
'

'
Range("A5526").Select
Selection.Copy
Application.CutCopyMode = False
ActiveSheet.Hyperlinks.Add Anchor:=Selection, Address:= _
"Franchise Ball | Player | Anbessa Corrales", TextToDisplay:= _
"Franchise Ball | Player | Anbessa Corrales"
Range("A5527").Select
Selection.Copy
Application.CutCopyMode = False
ActiveSheet.Hyperlinks.Add Anchor:=Selection, Address:= _
"Franchise Ball | Player | Jake Duggan", TextToDisplay:= _
"Franchise Ball | Player | Jake Duggan"
Range("A5528").Select
Selection.Copy
Application.CutCopyMode = False
ActiveSheet.Hyperlinks.Add Anchor:=Selection, Address:= _
"Franchise Ball | Player | Leroy Liu", TextToDisplay:= _
"Franchise Ball | Player | Leroy Liu"
End Sub
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
VBA Code:
Sub CreateHyperLinks()
    Dim sh As Worksheet
    Dim rng As Range, c As Range
    Set sh = ActiveSheet
    With sh
        Set rng = .Range("A1:A" & .Cells(.Rows.Count, "A").End(xlUp).Row)
        For Each c In rng.Cells
            .Hyperlinks.Add Anchor:=c, Address:=c.Value, TextToDisplay:=c.Value
        Next
    End With
End Sub
 
Upvote 0
Solution
VBA Code:
Sub CreateHyperLinks()
    Dim sh As Worksheet
    Dim rng As Range, c As Range
    Set sh = ActiveSheet
    With sh
        Set rng = .Range("A1:A" & .Cells(.Rows.Count, "A").End(xlUp).Row)
        For Each c In rng.Cells
            .Hyperlinks.Add Anchor:=c, Address:=c.Value, TextToDisplay:=c.Value
        Next
    End With
End Sub
 
Upvote 0

Forum statistics

Threads
1,215,737
Messages
6,126,575
Members
449,318
Latest member
Son Raphon

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top