var
iNumber, iName, iTown, iDate: secuencia;
Empleados, pagos: IXMLNode;
i: número entero;
comenzar
XMLDocument1.Active: = falso;
XMLDocument1.XML.LoadFromFile (
“C:\Temp4 - XML \ Project1 \ XMLSourceFile \ SourceFile - MasterDetail.xml ");
XMLDocument1.Active: = verdad;
Empleados: = XMLDocument1.DocumentElement;
para i: = 0 a Employees.ChildNodes.Count - 1 hace
comenzar
iNumber: = Employees.ChildNodes [i] .ChildNodes [“número”]. Texto;
iName: = Employees.ChildNodes [i] .ChildNodes [“nombre”]. Texto;
iTown: = Employees.ChildNodes [i] .ChildNodes [“ciudad”]. Texto;
Pagos: = Employees.ChildNodes [i] .ChildNodes [“pagos”];
iDate: = Payments.ChildNodes [“fecha”]. Texto;
ListBox1.Items.Add (iNumber + “,” + iName + “,” + iTown + “,” + iDate);
extremo;
extremo;
|