Hi I have a list of text (with hyperlink to web page) down the cloumn A and i was hoping to extract Just the URL into Column B.
Is this possible?
I have tried to research the VB script and I have found:
Sub GetLinkNameOnly()
Dim Adr As String
Dim NoOfAddresses As Integer
Dim CurrentRow As Integer
Dim x As Integer
x = 1: NoOfAddresses = 0
BeginCount: 'Get no of Addresses in Column "A"
If Cells(1 + x, 1) <> "" Then NoOfAddresses = NoOfAddresses + 1: x = x + 1 _
'Put Address in Column "B"
For x = 1 To NoOfAddresses
Adr = Worksheets(1).Range(Cells(2, 1), Cells(2 + NoOfAddresses, 1)).Hyperlinks(x).Address
Cells(1 + x, 2) = Adr
Next
MsgBox Application.UserName & " it's done now", vbInformation
End Sub
This script however only brings the URL for Cell "B2"
Can someone help me why this is the case and how to change the script so it'll so all of my URLs in my list?
I have approx 500 links to extract.
Thank you
Is this possible?
I have tried to research the VB script and I have found:
Sub GetLinkNameOnly()
Dim Adr As String
Dim NoOfAddresses As Integer
Dim CurrentRow As Integer
Dim x As Integer
x = 1: NoOfAddresses = 0
BeginCount: 'Get no of Addresses in Column "A"
If Cells(1 + x, 1) <> "" Then NoOfAddresses = NoOfAddresses + 1: x = x + 1 _
'Put Address in Column "B"
For x = 1 To NoOfAddresses
Adr = Worksheets(1).Range(Cells(2, 1), Cells(2 + NoOfAddresses, 1)).Hyperlinks(x).Address
Cells(1 + x, 2) = Adr
Next
MsgBox Application.UserName & " it's done now", vbInformation
End Sub
This script however only brings the URL for Cell "B2"
Can someone help me why this is the case and how to change the script so it'll so all of my URLs in my list?
I have approx 500 links to extract.
Thank you