We are trying to parse the below response and get the value "123456" from "result" tag using VBA Code but we are not getting anything:
Response Received:
------=_Part_119884_965967558.1620391101235
Content-Type: application/xop+xml;charset=utf-8;type="text/xml"
Content-Transfer-Encoding: 8bit
Content-ID: <e119e24d-e0b6-4ceb-a00a-dd094ef91ef7>
<?xml version="1.0" encoding="utf-8" ?>
<env:Envelope
xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:wsa="http://www.w3.org/2005/08/addressing">
<env:Header>
<wsa:Action>http://xxxx</wsa:Action>
<wsa:MessageID>urn:uuid:xxxx</wsa:MessageID>
</env:Header>
<env:Body>
<ns0:uploadFileResponse
xmlns:ns0="http://xxxx">
<result
xmlns="http://xxxx">123456
</result>
</ns0:uploadFileResponse>
</env:Body>
</env:Envelope>
------=_Part_119884_965967558.1620391101235--
VBA Code:
Dim xmldoc As Object
Dim xmlnode As Object
Set xmldoc = CreateObject("Microsoft.XMLDOM")
xmldoc.SetProperty "SelectionLanguage", "XPath"
xmldoc.async = False
xmldoc.LoadXML .ResponseText
For Each xmlnode In xmldoc.SelectNodes("//*[contains(name(),'result')]")
Debug.Print "Document ID: "; xmlnode.text
Next
Please help