Untitled

Anonymous
plain_text
03/19/2025 5:33 AM
508 B
12
Indexable
Function ExtractURL(rng As Range) As String

    ' Checks if the first cell in the specified range contains hyperlink
    If rng(1).Hyperlinks.Count <> 1 Then
    
        ' If not, returns an empty string
        ExtractURL = ""
    
    Else
        
        ' If there is a hyperlink, returns its URL
        ExtractURL = rng.Hyperlinks(1).Address
    
    End If

End Function
Editor is loading...
Leave a Comment