WinHttpRequest Demo : WinHttpRequest « File Path « VBA / Excel / Access / Word






WinHttpRequest Demo

 
Sub QuerybyAuthor()
    Dim ws As Worksheet
    Dim whr As New WinHttpRequest
    Dim lobj As ListObject
    Dim nCount As Integer
    Dim objSelected As Object

    Dim sURI As String

    Set objSelected = Selection
    Set ws = Worksheets("Sheet1")
    Set lobj = ws.ListObjects(1)

    Application.Cursor = xlWait

    sURI = "http://xml.amazon.com/"

    whr.Open "GET", sURI
    whr.Send

    ActiveWorkbook.XmlMaps(1).ImportXml whr.ResponseText

    Application.Cursor = xlDefault

End Sub

 








Related examples in the same category