Article View: borland.public.cppbuilder.internet.socket
Article #4014Re: how to create XMLDocument from text string
From: Daniel Stevenson
Date: Wed, 27 Apr 2005 07:44
Date: Wed, 27 Apr 2005 07:44
28 lines
2171 bytes
2171 bytes
> > I'm using BCB6, i have an application with a TServerSocket, I am being sent > > XML to my socket and I am struggling to turn the text string into a valid > > XML document using TXMLDocument. > > Could you please explain what has to be done/added before the xml that you > received is considered valid xml ? the XML I'm receiving is valid, but I'm can only receive it as text via the socket, and I want to put it into an XMLDocument so I can search for nodes and find data easily. The type of XML text I am receiving is ... "<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>\n<OAP-response version=\"3.0\" id=\"97302\">\n<Status service=\"supervision\"><Type>1</Type><Code>200</Code></Status>\n</OAP-respo nse>\n" > That is very unreliable code to begin with. Who guarantees > that RxBuffer contains all the data sent by the client ? > This approch will only go right when the client only now > and then sends small pieces of data (<10K or so ). I'm only in testing at this stage, I will clean up and ensure it is reliable once I can prove i can receive the data and manipulate it within a XMLDocument.
Technical Details
Message-ID:
<426f42d1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!zen.net.uk!dedekind.zen.co.uk!216.196.110.149.MISMATCH!border2.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mailReferences:
<426f30b1@newsgroups.borland.com> <426f3bd3@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,202e5b119b206323 X-Google-Attributes: gid11508e,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Daniel Stevenson" <daniel@ocreage.com.au> Newsgroups: borland.public.cppbuilder.internet.socket References: <426f30b1@newsgroups.borland.com> <426f3bd3@newsgroups.borland.com> Subject: Re: how to create XMLDocument from text string Date: Wed, 27 Apr 2005 17:44:11 +1000 Lines: 31 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 NNTP-Posting-Host: 202.174.233.53 Message-ID: <426f42d1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1114587857 202.174.233.53 (27 Apr 2005 00:44:17 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!zen.net.uk!dedekind.zen.co.uk!216.196.110.149.MISMATCH!border2.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail