Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

readin xml file 1

Status
Not open for further replies.

elly00

Technical User
Jun 30, 2011
69
IT
Hi,
using vbs I need to read the various sections present in a file named (dettaglio linee).
The file is like that:
<DettaglioLinee>
<NumeroLinea>1</NumeroLinea>
<CodiceArticolo>
<CodiceTipo>SA</CodiceTipo>
<CodiceValore>a1ss</CodiceValore>
</CodiceArticolo>
<Descrizione>ddddd</Descrizione>
<Quantita>1.00</Quantita>
<UnitaMisura>n</UnitaMisura>
<PrezzoUnitario>5250.00</PrezzoUnitario>
<PrezzoTotale>5250.00</PrezzoTotale>
<AliquotaIVA>22.00</AliquotaIVA>
</DettaglioLinee>
<DettaglioLinee>
<NumeroLinea>2</NumeroLinea>
<Descrizione>bbbbbb</Descrizione>
<PrezzoUnitario>0.00</PrezzoUnitario>
<PrezzoTotale>0.00</PrezzoTotale>
<AliquotaIVA>22.00</AliquotaIVA>
</DettaglioLinee>

I can read the first section I found using this command

set node=objxmldoc.selectsinglenode("//DatiBeniServizi/DettaglioLinee")
set valore = node.getElementsByTagName("NumeroLinea")
NUMLINEA= (valore(0).childNodes(0).Text)

But i don't know how can I set a For - Next in order to read all the sctions founded in the file...

Thanks

 
@mikrom,

SUGGESTION: put these examples in one or more FAQs as How to...

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
"The most incomprehensible thing about the universe is that it is comprehensible" A. Einstein
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top