This is function used to extract hyperlinks or urls from a cell in excel.
Open your excel sheet. Press Alt+F11. Then in the vba editor that appearrs go to menu
insert–>module. Paste the following function there and now press alt+q.
Function getURL(forThisCell As Range) As String
‘VBA UDF for getting URLs from a cell if any
retVal = “”
If forThisCell.Hyperlinks(1).Address <> “” Then
retVal = forThisCell.Hyperlinks(1).Address
End If
getURL = retVal
End Function
Now if you want to extract link from the cell A1 then enter the following in any of the cell
=getURL(A1)