Re: [xmljs-users] Parsing dynamic XML recursively
Brought to you by:
djoham,
witchhunter
From: David J. <dj...@ya...> - 2005-08-05 16:52:29
|
Depending on what you're trying to do, the SAX parser might suite your needs very well. If you need to use the DOM, take a look at the DOMNode documentation for getNextSibling and getPreviousSibling. Those will probably get you what you're looking for. At the very least, you can always count the child nodes and do a manual loop... HTH David --- James Watson <swi...@ho...> wrote: > I could not find an answer in the archives ... I would think (hope) there is > a simple solution. > > I have a dynamically generated XML document that containts a data grid. It > looks like this: > > ... > <datarow> > <data>45.567</data> > <data>33.552</data> > </datarow> > <datarow> > <data>67.132</data> > <data>45.297</data> > </datarow> > ... > > How can I iterate through the XML, reading each row, and then each cell? I > started off by searching for a command along the lines of > getNextNode/getNextChildNode, etc., but I am stumped on how to do this. All > the examples seem to point to specific (known) nodes, and unique nodes at > that. > > Any help is appreciated. > > > -J > > > > > ------------------------------------------------------- > SF.Net email is Sponsored by the Better Software Conference & EXPO > September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices > Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA > Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf > _______________________________________________ > xmljs-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmljs-users > |