comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » loop for XML
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
loop for XML [message #89824] Sat, 06 December 2014 05:17 Go to previous message
skymaxwell@gmail.com is currently offline  skymaxwell@gmail.com
Messages: 127
Registered: January 2007
Senior Member
Hi

I need read the XML file. Here is the fragment of file

<root>
<Key1>
<p1>13</p1>
<tb1>10</tb1>
</Key1>
<KeyMeta>
<ax>21</ax>
<ay>59</ay>
<az>26.7</az>
</KeyMeta>
</root>


I was looking here something about XML, I find simple example with single tag
There used these functions (oValue->GetFirstChild())->GetNodeValue())


How build construction for multiple tags as my case ?
I didn't find any functions in IDL help, which i could use in my case.
May be I don't understand function Item(i).

Here part of code
==============
p=OBJ_NEW('IDLffXMLDOMDocument')
p->Load,FILENAME=filenameXML
oTopLevel=p->GetDocumentElement() ;return root IDLffXMLDOMDocument
; tag with name
mainTagsList=oTopLevel->GetElementsByTagName("KeyMeta")
; how many KeyMeta tags in documents
PRINT,"Length=",mainTagsList->GetLength()
;loop
FOR i=0,mainTagsList->GetLength()-1 DO BEGIN
;How to do correct loop ???
ENDFOR

==============


thanks
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Referencing structure inline
Next Topic: help regarding curvefit

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 09:18:42 PDT 2025

Total time taken to generate the page: 0.00402 seconds