Discussion:
SOAP & XML parsing
(too old to reply)
AEJ45
2012-02-02 10:37:42 UTC
Permalink
Hello. I have the following SOAP Response document:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/
envelope/">

<soapenv:Body>
<ns3:performTitleKnownSearchResponse xmlns:ns1="http://
www.oscre.org/ns/eReg-Final/2011/RequestTitleKnownOfficialCopyV2_0"
xmlns:ns3="http://officialcopyv2_0.ws.bg.lr.gov/"
xmlns:ns4="http://www.oscre.org/ns/eReg-Final/2011/
ResponseTitleKnownOfficialCopyV2_0">

<return>
<ns4:GatewayResponse>
<ns4:TypeCode>30</ns4:TypeCode>
<ns4:Results>
<ns4:ExternalReference>
<ns4:Reference>c</ns4:Reference>
</ns4:ExternalReference>
<ns4:ActualPrice>
<ns4:GrossPriceAmount>4.00</ns4:GrossPriceAmount>
</ns4:ActualPrice>
<ns4:Attachment>
<ns4:EmbeddedFileBinaryObject ns4:format="PDF">
This tag contains Base64 Encoded Binary Data for
a pdf file.
</ns4:EmbeddedFileBinaryObject>
</ns4:Attachment>
<ns4:ResultTypeCode>10</ns4:ResultTypeCode>
<ns4:HMLRReference>
<ns4:Reference>8CBBDVB</ns4:Reference>
</ns4:HMLRReference>
</ns4:Results>
</ns4:GatewayResponse>
</return>
</ns3:performTitleKnownSearchResponse>
</soapenv:Body>
</soapenv:Envelope>

I have tried many methods of reading the data but every time I try to
read an individual node I get an Object or With Block not set.

I need to read through the document, extract the Base64 Binary and
save it to a pdf file. Any help would be appreciated.

Thanks
Deanna Earley
2012-02-02 12:11:09 UTC
Permalink
<SNIP>
Post by AEJ45
I have tried many methods of reading the data but every time I try to
read an individual node I get an Object or With Block not set.
I need to read through the document, extract the Base64 Binary and
save it to a pdf file. Any help would be appreciated.
What code have you tried?
It's fairly straight forward XML parsing complicated slightly by the use
of namespaces.

An alternative to SelectSingleNode() is to use nested loops and check
the element names.
--
Deanna Earley (***@icode.co.uk)
i-Catcher Development Team
http://www.icode.co.uk/icatcher/

iCode Systems

(Replies direct to my email address will be ignored.
Please reply to the group.)
Loading...