xml help

Post Reply
Wanderson
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

xml help

Post by Wanderson »

About the xml below, how I can read a especific value of especific node? If a do xmlNode := xmlIter:Find('CNPJ') i get the first node (<emit>) CNPJ value 7094099400877. But I want to get directly the value of CNPJ in node <dest>
Thanks in advance.

- <emit>
<CNPJ>70940994008277</CNPJ>
<xNome>PANDURATA ALIMENTOS LTDA.EXTR. KM 937,2 ESTAB.170</xNome>
<xFant>PANDURATA/82</xFant>
- <enderEmit>
<xLgr>ROD BR-381 FERNAO DIAS</xLgr>
<nro>K 937</nro>
<xCpl>2 S/N</xCpl>
<xBairro>ROSEIRA</xBairro>
<cMun>3125101</cMun>
<xMun>EXTREMA</xMun>
<UF>MG</UF>
<CEP>37640000</CEP>
<cPais>1058</cPais>
<xPais>BRASIL</xPais>
</enderEmit>
<IE>2512872330491</IE>
<CRT>3</CRT>
</emit>
- <dest>
<CNPJ>01937635000859</CNPJ>
<xNome>SONDA SUPERM EXP IMP LTDA</xNome>
- <enderDest>
<xLgr>AV SENADOR TEOTONIO VILELA</xLgr>
<nro>5800</nro>
<xBairro>JARDIM SAO JOSE</xBairro>
<cMun>3550308</cMun>
<xMun>SAO PAULO</xMun>
<UF>SP</UF>
<CEP>04804000</CEP>
<cPais>1058</cPais>
<xPais>BRASIL</xPais>
<fone>1131790160</fone>
</enderDest>
<IE>115051646110</IE>
</dest>
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Re: xml help

Post by Antonio Linares »

Wanderson,

You may review FWH\samples\xmlreader.prg and xmltree.prg which are good examples for using trees
regards, saludos

Antonio Linares
www.fivetechsoft.com
Wanderson
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

Re: xml help

Post by Wanderson »

Thank you Antonio.
Post Reply