Public Function GoogleURL(txt As String) As String
Dim oXMLH As New MSXML2.XMLHTTP60
Dim oDoc As New HTMLDocument
Dim oResults As Object
With oXMLH
.Open "GET", "https://www.google.fr/search?q=" & txt, False
.send
oDoc.body.innerHTML = .responseText
End With
Set oResults = oDoc.getElementsByClassName("r")
If oResults.Length = 0 Then
GoogleURL = "#N/A"
Else
GoogleURL = oResults(0).FirstChild.href
End If
End Function