I have the following XML.
<ArrayOfRapJ xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/pluriel.Models">
<Rapj>
<Libdep>% Fréquentation:</Libdep>
<Total>36.860068259385665529010238910</Total>
</Rapj>
I am using the following Delphi code to read the <Libdep>
and <Total>
values:
var
DOC: IXMLDocument;
i: Integer;
OrderChilds, E1EDP01_Node: IXMLNode;
begin
DOC := LoadXMLDocument('d:\Rapjrnprests.xml');
for i := 0 to DOC.ChildNodes.Nodes['ArrayOfRapJ'].ChildNodes.Count - 1 do
begin
OrderChilds := DOC.ChildNodes.Nodes['RapJ'].ChildNodes[i];
if OrderChilds.NodeName = 'RapJ' then
begin
E1EDP01_Node := OrderChilds.ChildNodes.Nodes['Libdep'];
if Assigned(E1EDP01_Node) then
Memo1.Lines.Add(E1EDP01_Node.ChildNodes.Nodes['Total'].NodeValue)
end;
end;
The XML is using URL namespaces. How do I read the values?