Y
YYZ
Hi guys. When I receive an XML string via the net (HttpWebResponse), I
can't load it into an Xml.XmlDocument object. However, if I take that
exact same string of XML and load it up in another program, it works
fine. Here's what I mean:
sResponse has been received via the web and is immediately used like
this:
dim ParseResponse as Xml.XmlDocument
ParseResponse.LoadXML(sResponse) <-- error here -- "An unhandled
exception of type 'System.Xml.XmlException' occurred in system.xml.dll"
sResponse looks like this:
<?xml version='1.0' encoding='UTF-8' ?>
<ns0:LALSXML xmlns:ns0="http://Client.LALS.Ack.Version1">
<Status>SUCCESS</Status>
<StatusCode>SUCCESS</StatusCode>
<StatusMessage></StatusMessage>
<TransactionID>66d4bf32-22c8-46c1-9248-80fe280e733e</TransactionID>
<ClientOrderID>060283000009-1</ClientOrderID>
<ClientLineItemID></ClientLineItemID>
<ReceivedDateTime>2006/24/05</ReceivedDateTime>
</ns0:LALSXML>
If I put that XML into a string variable in another program and then
load it up the same way into an XMLDocument object, it loads fine and I
can start enumerating nodes.
Can anyone point me in a likely direction for a solution here? What
might I be doing wrong?
Matt
can't load it into an Xml.XmlDocument object. However, if I take that
exact same string of XML and load it up in another program, it works
fine. Here's what I mean:
sResponse has been received via the web and is immediately used like
this:
dim ParseResponse as Xml.XmlDocument
ParseResponse.LoadXML(sResponse) <-- error here -- "An unhandled
exception of type 'System.Xml.XmlException' occurred in system.xml.dll"
sResponse looks like this:
<?xml version='1.0' encoding='UTF-8' ?>
<ns0:LALSXML xmlns:ns0="http://Client.LALS.Ack.Version1">
<Status>SUCCESS</Status>
<StatusCode>SUCCESS</StatusCode>
<StatusMessage></StatusMessage>
<TransactionID>66d4bf32-22c8-46c1-9248-80fe280e733e</TransactionID>
<ClientOrderID>060283000009-1</ClientOrderID>
<ClientLineItemID></ClientLineItemID>
<ReceivedDateTime>2006/24/05</ReceivedDateTime>
</ns0:LALSXML>
If I put that XML into a string variable in another program and then
load it up the same way into an XMLDocument object, it loads fine and I
can start enumerating nodes.
Can anyone point me in a likely direction for a solution here? What
might I be doing wrong?
Matt