Customizing text in Hyperlink

Copper Contributor

I have a column of hyperlinks referencing different map locations on Google Maps.  Is there a way to change the entire column to a simple "Map It" instead of the long address?  I see how I can do one address at a time by right clicking but I have hundreds of addresses and am trying to keep all the information on one page.

1 Reply

@Jimblackbook, you can do this with a macro.

Right-click on the sheet tab name where you have the hyperlinks.

Choose view code.

On the window that opens paste the following code:

 

Sub EditHyperLinks()
Dim i As Long
'Replace numbers 2 and 3 to be the row numbers of the first cell and the last cell of the list of hyperlinks in your column
For i = 2 To 4
'Replace B with the letter for the column in which you have the hyperlinks
Range("B" & i).Hyperlinks(1).TextToDisplay = "Map it"
Next i
End Sub

 

Read the green text rows and follow the instructions to change the code in the row right below according to your file.

Click F5 to run the macro.

 

Let me know if you need further assistance.

Good luck!