Hamlet081299
asked on
XML parser
I need to parse an XML document, but I am finding limitations with the TXMLDocument component in Delphi 6.
I hope that someone can indicate a way around these problems, but if not a suggestion of a good solid alternate XML component will win the points.
Here's a simple example of the kind of document I need to parse...
<template>
<logo/>
<p>Here is some <b>bolded</b> text</p>
<p>A field gets inserted here <field name="afield" width="10" align="right"/></p>
</template>
When I try to traverse the nodes there are problems because of the embedded tags (e.g. <b> inside <p>) that make it hard to get to the text (e.g. the "Here is some " part).
Ideas?
I hope that someone can indicate a way around these problems, but if not a suggestion of a good solid alternate XML component will win the points.
Here's a simple example of the kind of document I need to parse...
<template>
<logo/>
<p>Here is some <b>bolded</b> text</p>
<p>A field gets inserted here <field name="afield" width="10" align="right"/></p>
</template>
When I try to traverse the nodes there are problems because of the embedded tags (e.g. <b> inside <p>) that make it hard to get to the text (e.g. the "Here is some " part).
Ideas?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
TurboPower at www.turbopower.com has an XML Parser as well.
ASKER
In the end I have gone back to the built in XML component. I found that with a bit of tweaking it was able to do what I wanted.
The destructor implementation was okay, but didn;t quite give me the level of control I wanted.
The destructor implementation was okay, but didn;t quite give me the level of control I wanted.
ASKER